MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / safeGetString

Function safeGetString

apps/kimi-web/src/lib/storage.ts:55–61  ·  view source on GitHub ↗
(key: string)

Source from the content-addressed store, hash-verified

53}
54
55export function safeGetString(key: string): string | null {
56 try {
57 return globalThis.localStorage.getItem(key);
58 } catch {
59 return null;
60 }
61}
62
63export function safeSetString(key: string, value: string): void {
64 try {

Callers 15

detectFunction · 0.90
isTraceEnabledFunction · 0.90
getClientIdFunction · 0.90
loadDraftFunction · 0.90
loadSidebarCollapsedFunction · 0.90
readStoredFunction · 0.90
loadThinkingFromStorageFunction · 0.90
loadModeMapFromStorageFunction · 0.90

Calls 1

getItemMethod · 0.65

Tested by

no test coverage detected