Remove localStorage write verification

This commit is contained in:
Eric Bailey
2026-08-31 13:47:46 -05:00
parent 3c554725a3
commit 3f31e1dd72
2 changed files with 2 additions and 5 deletions
+2 -2
View File
@@ -226,7 +226,7 @@ Tab A action: broadcast update notification
Broadcasting after a failed write would tell Tab B to reread localStorage while it still contains `(7, A)`, spreading the stale generation instead of the new one. Broadcasting after a failed write would tell Tab B to reread localStorage while it still contains `(7, A)`, spreading the stale generation instead of the new one.
After successfully writing and verifying localStorage, notify other tabs: After successfully writing localStorage, notify other tabs:
```ts ```ts
broadcast.postMessage({ broadcast.postMessage({
@@ -310,7 +310,7 @@ Read authoritative localStorage state
Conditionally commit against active base jti Conditionally commit against active base jti
| |
v v
Write and verify localStorage Write localStorage
| |
+-- failure -> report or retry; do not broadcast +-- failure -> report or retry; do not broadcast
| |
-3
View File
@@ -208,9 +208,6 @@ function writeToStorage(value: Schema) {
} }
try { try {
localStorage.setItem(BSKY_STORAGE, rawData) localStorage.setItem(BSKY_STORAGE, rawData)
if (localStorage.getItem(BSKY_STORAGE) !== rawData) {
throw new Error('Failed to verify persisted state')
}
} catch (error) { } catch (error) {
logger.error('persisted state: failed writing root state to storage', { logger.error('persisted state: failed writing root state to storage', {
message: error, message: error,