diff options
| author | toasted-nutbread <toasted-nutbread@users.noreply.github.com> | 2021-03-14 22:51:48 -0400 | 
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-03-14 22:51:48 -0400 | 
| commit | 49b603c7561c1f39cd79c969e00b6069cedb2397 (patch) | |
| tree | 8aea4642daa2d568579399ead8ca1bee236afca2 /ext/js/background | |
| parent | a52d86a39e9cca620823e3d97d7c129a7abafced (diff) | |
Remove old settings page (#1524)
* Remove old settings page
* Remove spinner.gif
Diffstat (limited to 'ext/js/background')
| -rw-r--r-- | ext/js/background/backend.js | 31 | 
1 files changed, 10 insertions, 21 deletions
| diff --git a/ext/js/background/backend.js b/ext/js/background/backend.js index a2a93375..ff119cf2 100644 --- a/ext/js/background/backend.js +++ b/ext/js/background/backend.js @@ -1945,31 +1945,20 @@ class Backend {      }      async _openSettingsPage(mode) { -        const {useSettingsV2} = this._options.global;          const manifest = chrome.runtime.getManifest(); -        const url = chrome.runtime.getURL(useSettingsV2 ? manifest.options_ui.page : '/settings-old.html'); +        const url = chrome.runtime.getURL(manifest.options_ui.page);          switch (mode) {              case 'existingOrNewTab': -                if (!useSettingsV2) { -                    const predicate = ({url: url2}) => (url2 !== null && url2.startsWith(url)); -                    const tab = await this._findTabs(1000, false, predicate, false); -                    if (tab !== null) { -                        await this._focusTab(tab); -                    } else { -                        await this._createTab(url); -                    } -                } else { -                    await new Promise((resolve, reject) => { -                        chrome.runtime.openOptionsPage(() => { -                            const e = chrome.runtime.lastError; -                            if (e) { -                                reject(new Error(e.message)); -                            } else { -                                resolve(); -                            } -                        }); +                await new Promise((resolve, reject) => { +                    chrome.runtime.openOptionsPage(() => { +                        const e = chrome.runtime.lastError; +                        if (e) { +                            reject(new Error(e.message)); +                        } else { +                            resolve(); +                        }                      }); -                } +                });                  break;              case 'newTab':                  await this._createTab(url); |