Adjust use of chrome.storage.managed for Opera
It turns out that chrome.storage.managed is defined for Opera, so the previous feature detection method did not work.
This commit is contained in:
parent
1d9dc37337
commit
c9b3ea2f84
@ -204,11 +204,15 @@ var Preferences = {
|
||||
// // These preferences can be overridden by the user.
|
||||
// chrome.storage.managed.get(DEFAULT_PREFERENCES, getPreferences);
|
||||
// } else {
|
||||
// // Managed storage not supported, e.g. in Opera.
|
||||
// // Managed storage not supported, e.g. in old Chromium versions.
|
||||
// getPreferences(DEFAULT_PREFERENCES);
|
||||
// }
|
||||
//
|
||||
// function getPreferences(defaultPrefs) {
|
||||
// if (chrome.runtime.lastError) {
|
||||
// // Managed storage not supported, e.g. in Opera.
|
||||
// defaultPrefs = DEFAULT_PREFERENCES;
|
||||
// }
|
||||
// chrome.storage.local.get(defaultPrefs, function(readPrefs) {
|
||||
// resolve(readPrefs);
|
||||
// });
|
||||
|
Loading…
Reference in New Issue
Block a user