MCPcopy Create free account
hub / github.com/BrainicHQ/DoHSpeedTest / writeStoredJson

Function writeStoredJson

script.js:89–97  ·  view source on GitHub ↗
(key, value)

Source from the content-addressed store, hash-verified

87}
88
89function writeStoredJson(key, value) {
90 try {
91 localStorage.setItem(key, JSON.stringify(value));
92 return true;
93 } catch (error) {
94 console.warn(`Unable to persist settings for ${key}`, error);
95 return false;
96 }
97}
98
99function normalizeCountryCode(value) {
100 if (typeof value !== 'string') return '';

Callers 2

persistHostnamesFunction · 0.85
persistDoHServersFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected