fix: restore LABELS const
This commit is contained in:
parent
64c222b172
commit
b41839e529
1 changed files with 3 additions and 0 deletions
|
|
@ -28,6 +28,9 @@ async function searchToken(exchange: string, query: string): Promise<string | nu
|
|||
} catch { return null; }
|
||||
}
|
||||
|
||||
const LABELS: Record<string, { label: string; unit: string }> = {};
|
||||
for (const t of INDEX_TOKENS) { LABELS[t.key] = { label: t.label, unit: t.unit }; }
|
||||
|
||||
function saveToCache(quotes: MarketQuote[]): void {
|
||||
const upsert = db.prepare(`INSERT INTO market_cache (key,label,price,change_val,change_pct,unit,cached_at)
|
||||
VALUES (@key,@label,@price,@change_val,@change_pct,@unit,datetime('now'))
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue