From 51ad84e6a9f7bf1501aca5b212772005b786652c Mon Sep 17 00:00:00 2001 From: tophf Date: Wed, 13 Dec 2017 05:34:44 +0300 Subject: [PATCH] don't open the homepage on first install as it's not helpful see #112 --- background/background.js | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/background/background.js b/background/background.js index 7c9e1012..0d0bce79 100644 --- a/background/background.js +++ b/background/background.js @@ -63,18 +63,6 @@ prefs.subscribe(['iconset'], () => updateIcon({id: undefined}, {})); { const onInstall = ({reason}) => { chrome.runtime.onInstalled.removeListener(onInstall); - const manifest = chrome.runtime.getManifest(); - // Open FAQs page once after installation to guide new users. - // Do not display it in development mode. - if (reason === 'install' && manifest.update_url) { - // don't hardcode homepage URL, extract it from "Get Help" label translation - // TODO: add a built-in tour page in the extension - const getHelpHtml = chrome.i18n.getMessage('manageText').match(/]+/g); - const url = (getHelpHtml[1] || '').replace(/^.+?=\s*/, '').replace(/^['"]|["']$/g, ''); - if (url) { - setTimeout(openURL, 100, {url}); - } - } // reset L10N cache on update if (reason === 'update') { localStorage.L10N = JSON.stringify({