Remove unnecessary API method
This commit is contained in:
parent
21b6429205
commit
9250d5c624
|
@ -50,12 +50,6 @@ window.API_METHODS = Object.assign(window.API_METHODS || {}, {
|
||||||
return browser.runtime.openOptionsPage()
|
return browser.runtime.openOptionsPage()
|
||||||
.then(() => new Promise(resolve => setTimeout(resolve, 100)))
|
.then(() => new Promise(resolve => setTimeout(resolve, 100)))
|
||||||
.then(() => msg.broadcastExtension({method: 'optionsCustomizeHotkeys'}));
|
.then(() => msg.broadcastExtension({method: 'optionsCustomizeHotkeys'}));
|
||||||
},
|
|
||||||
|
|
||||||
installType() {
|
|
||||||
// types: "admin", "development", "normal", "sideload" & "other"
|
|
||||||
// "normal" = addon installed from webstore
|
|
||||||
return chrome.management.getSelf(info => localStorage.installType = info.installType);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -150,8 +144,9 @@ chrome.runtime.onInstalled.addListener(({reason}) => {
|
||||||
});
|
});
|
||||||
// themes may change
|
// themes may change
|
||||||
delete localStorage.codeMirrorThemes;
|
delete localStorage.codeMirrorThemes;
|
||||||
// save install type
|
// save install type: "admin", "development", "normal", "sideload" or "other"
|
||||||
window.API_METHODS.installType();
|
// "normal" = addon installed from webstore
|
||||||
|
chrome.management.getSelf(info => localStorage.installType = info.installType);
|
||||||
});
|
});
|
||||||
|
|
||||||
// *************************************************************************
|
// *************************************************************************
|
||||||
|
|
Loading…
Reference in New Issue
Block a user