MCPcopy Create free account
hub / github.com/TeleBoxOrg/TeleBox_Plugins / writeConfig

Function writeConfig

speedtest/speedtest.ts:197–206  ·  view source on GitHub ↗
(patch: Partial<SpeedtestConfig>)

Source from the content-addressed store, hash-verified

195 } catch (error: any) {
196 console.error("Failed to write config:", error);
197 }
198}
199
200function getDefaultServer(): number | null {
201 const cfg = readConfig();
202 return cfg.default_server_id ?? null;
203}
204
205function saveDefaultServer(serverId: number | null): void {
206 writeConfig({ default_server_id: serverId });
207}
208
209function removeDefaultServer(): void {

Callers 2

saveDefaultServerFunction · 0.85
savePreferredTypeFunction · 0.85

Calls 3

readConfigFunction · 0.85
errorMethod · 0.80
ensureDirectoriesFunction · 0.70

Tested by

no test coverage detected