[Storage > Parity] Fix not using async

pull/55/head
Oj18 3 years ago
parent b9fe8dfea3
commit 481199d2e0

@ -199,13 +199,13 @@ const init = async function () {
this.moduleSettingsStore.saveModuleSettings();
}, 3000);
this.remove = () => {
this.remove = async () => {
this.settingsUninjects.forEach((x) => x());
clearInterval(this.saveInterval);
clearInterval(this.hotupdateInterval);
this.storage.clear();
await this.storage.clear();
this.removed = true;

@ -55,7 +55,7 @@ export const remove = (key) => {
backup();
};
export const clear = () => {
export const clear = async () => {
keys().filter((x) => x.toLowerCase().startsWith('goosemod')).forEach((y) => remove(x)); // Extension
for (const system of paritySystems) await system.clear();

@ -218,7 +218,7 @@ export default (goosemodScope, gmSettings, Items) => {
onclick: async () => {
if (await goosemodScope.confirmDialog('Reset', 'Reset GooseMod', 'Confirming will completely reset GooseMod, removing all preferences and modules; as if you had installed GooseMod for the first time. This is irreversible.')) {
goosemodScope.remove();
await goosemodScope.remove();
window.location.reload();
}
}

Loading…
Cancel
Save