This commit is contained in:
David Ralph 2018-12-26 11:45:56 +00:00 committed by GitHub
parent fcc74c171f
commit acd2e08267
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 9 deletions

View File

@ -1,17 +1,13 @@
// Original code sourced from https://forums.opera.com/topic/25046/how-to-disable-completely-the-speed-dial/14
chrome.tabs.onCreated.addListener(function(tab) {
chrome.tabs.onCreated.addListener((tab) => {
if (tab.status === "complete" && tab.url === "chrome://startpage/") {
chrome.tabs.update(tab.id, {
url: chrome.extension.getURL("index.html")
});
chrome.tabs.update(tab.id, { url: chrome.extension.getURL("index.html") });
}
});
chrome.tabs.onUpdated.addListener(function(tabId, changeInfo, tab) {
chrome.tabs.onUpdated.addListener((tabId, changeInfo, tab) => {
if (changeInfo.status === "complete" && tab.url === "chrome://startpage/") {
chrome.tabs.update(tabId, {
url: chrome.extension.getURL("index.html")
});
chrome.tabs.update(tabId, { url: chrome.extension.getURL("index.html") });
}
});
});