diff --git a/src/manifest.json b/src/manifest.json index f43e7be..424262e 100755 --- a/src/manifest.json +++ b/src/manifest.json @@ -3,7 +3,7 @@ "name": "Vytal", "version": "2.0.0", "description": "Spoof your location data and user agent.", - "permissions": ["storage", "debugger", "activeTab", "alarms"], + "permissions": ["storage", "debugger", "activeTab"], "background": { "service_worker": "background.bundle.js" }, "action": { "default_popup": "popup.html", diff --git a/src/pages/Background/index.js b/src/pages/Background/index.js index 2f401b1..4d04d9d 100644 --- a/src/pages/Background/index.js +++ b/src/pages/Background/index.js @@ -1,5 +1,4 @@ import attachDebugger from '../../utils/attachDebugger' -import userAgents from '../../utils/userAgents' const attachTab = (tabId) => { chrome.debugger.getTargets((tabs) => { @@ -21,17 +20,3 @@ chrome.tabs.onActivated.addListener((tab) => { chrome.tabs.onUpdated.addListener((tabId) => { attachTab(tabId) }) - -chrome.alarms.onAlarm.addListener((alarm) => { - if (alarm.name === 'userAgentAlarm') { - chrome.storage.sync.get(['randomUA'], (result) => { - if (result.randomUA) { - const randomUserAgent = - userAgents[Math.floor(Math.random() * userAgents.length)] - chrome.storage.sync.set({ - userAgent: randomUserAgent, - }) - } - }) - } -})