diff --git a/src/settings/handlers/AbstractLocalStorageSettingsHandler.ts b/src/settings/handlers/AbstractLocalStorageSettingsHandler.ts index 902c00f7a16..5d64009b6fe 100644 --- a/src/settings/handlers/AbstractLocalStorageSettingsHandler.ts +++ b/src/settings/handlers/AbstractLocalStorageSettingsHandler.ts @@ -29,8 +29,13 @@ export default abstract class AbstractLocalStorageSettingsHandler extends Settin // Listen for storage changes from other tabs to bust the cache window.addEventListener("storage", (e: StorageEvent) => { - this.itemCache.delete(e.key); - this.objectCache.delete(e.key); + if (e.key === null) { + this.itemCache.clear(); + this.objectCache.clear(); + } else { + this.itemCache.delete(e.key); + this.objectCache.delete(e.key); + } }); }