()
| 37 | private static initialized = false; |
| 38 | |
| 39 | private static init(): void { |
| 40 | if (this.initialized) return; |
| 41 | try { |
| 42 | this.db = new Database(GEMINI_CONFIG_DB_PATH); |
| 43 | this.db.exec(`CREATE TABLE IF NOT EXISTS config (key TEXT PRIMARY KEY, value TEXT NOT NULL)`); |
| 44 | this.initialized = true; |
| 45 | } catch (error) { |
| 46 | console.error("[convert] Failed to initialize Gemini config DB:", error); |
| 47 | } |
| 48 | } |
| 49 | |
| 50 | static get(key: string): string { |
| 51 | this.init(); |