(target: PersistTarget, platform: Platform)
| 516 | } |
| 517 | |
| 518 | function resolveTarget(target: PersistTarget, platform: Platform): PersistTarget { |
| 519 | if (target.scope !== "window") return target |
| 520 | if (platform.platform === "desktop" && !platform.windowID) return { ...target, storage: GLOBAL_STORAGE } |
| 521 | const windowID = platform.platform === "desktop" ? (platform.windowID ?? "browser") : "browser" |
| 522 | return { |
| 523 | ...target, |
| 524 | storage: windowStorage(windowID), |
| 525 | } |
| 526 | } |
| 527 | |
| 528 | export function removePersisted( |
| 529 | target: { storage?: string; legacyStorageNames?: string[]; key: string }, |
no test coverage detected