Fix: the return type of dbExecChromeStorage('put') is wrong

This commit is contained in:
eight 2020-02-08 01:21:12 +08:00
parent f32b6b6989
commit a473020dbe

View File

@ -169,7 +169,7 @@ const db = (() => {
});
}
return chromeLocal.setValue(STYLE_KEY_PREFIX + data.id, data)
.then(() => (chrome.runtime.lastError ? Promise.reject() : data.id));
.then(() => ({target: {result: data.id}}));
case 'putMany': {
const newItems = data.filter(i => !i.id);