(key: string)
| 35 | } |
| 36 | |
| 37 | function readStored(key: string): number | null { |
| 38 | try { |
| 39 | const raw = safeGetString(key); |
| 40 | if (raw === null) return null; |
| 41 | const n = Number(raw); |
| 42 | return Number.isFinite(n) ? n : null; |
| 43 | } catch { |
| 44 | return null; |
| 45 | } |
| 46 | } |
| 47 | |
| 48 | function writeStored(key: string, value: number): void { |
| 49 | try { |
no test coverage detected