Handle invalid bunker url, update synced stores

This commit is contained in:
Jon Staab
2025-07-15 11:06:47 -07:00
parent e2a0672ca5
commit 6f6bb508db
6 changed files with 61 additions and 19 deletions
+6 -2
View File
@@ -1,5 +1,5 @@
import {derived} from "svelte/store"
import {synced, throttled} from "@welshman/store"
import {synced, localStorageProvider, throttled} from "@welshman/store"
import {pubkey} from "@welshman/app"
import {prop, spec, identity, now, groupBy} from "@welshman/lib"
import type {TrustedEvent} from "@welshman/util"
@@ -16,7 +16,11 @@ import {chats, getUrlsForEvent, userRoomsByUrl, repositoryStore} from "@app/stat
// Checked state
export const checked = synced<Record<string, number>>("checked", {})
export const checked = synced<Record<string, number>>({
key: "checked",
defaultValue: {},
storage: localStorageProvider,
})
export const deriveChecked = (key: string) => derived(checked, prop(key))