Settings.get fix for chrome and edge
This commit is contained in:
parent
6bb4e97f64
commit
358863e7ef
@ -127,15 +127,15 @@ class Settings {
|
||||
return undefined;
|
||||
}
|
||||
} else if (currentBrowser.chrome) {
|
||||
const ret = new Promise( (resolve, reject) => {
|
||||
const ret = await new Promise( (resolve, reject) => {
|
||||
chrome.storage.local.get('uwSettings', (res) => resolve(res));
|
||||
});
|
||||
return ret['uwSettings'];
|
||||
return JSON.parse(ret['uwSettings']);
|
||||
} else if (currentBrowser.edge) {
|
||||
const ret = new Promise( (resolve, reject) => {
|
||||
const ret = await new Promise( (resolve, reject) => {
|
||||
browser.storage.local.get('uwSettings', (res) => resolve(res));
|
||||
});
|
||||
return ret['uwSettings'];
|
||||
return JSON.parse(ret['uwSettings']);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user