MCPcopy Index your code
hub / github.com/massCodeIO/massCode / readString

Function readString

src/main/store/sanitize.ts:11–17  ·  view source on GitHub ↗
(
  source: Record<string, unknown>,
  key: string,
  fallback: string,
)

Source from the content-addressed store, hash-verified

9}
10
11export function readString(
12 source: Record<string, unknown>,
13 key: string,
14 fallback: string,
15): string {
16 return typeof source[key] === 'string' ? String(source[key]) : fallback
17}
18
19export function readNullableString(
20 source: Record<string, unknown>,

Callers 5

sanitizeMathSettingsFunction · 0.90
sanitizePreferencesFunction · 0.90
sanitizeDonationsFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected