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

Method getAll

outdated/gemini/gemini.ts:103–118  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

101 }
102
103 static getAll(): { [key: string]: string } {
104 this.init();
105 try {
106 const stmt = this.db.prepare("SELECT key, value FROM config");
107 const rows = stmt.all() as { key: string; value: string }[];
108
109 const config: { [key: string]: string } = {};
110 rows.forEach(row => {
111 config[row.key] = row.value;
112 });
113 return config;
114 } catch (error) {
115 console.error("读取所有配置失败:", error);
116 return {};
117 }
118 }
119
120 static delete(key: string): void {
121 this.init();

Callers

nothing calls this directly

Calls 2

initMethod · 0.95
errorMethod · 0.80

Tested by

no test coverage detected