From 1db0e6ae9865dcccf15453f8b51b116f12178789 Mon Sep 17 00:00:00 2001 From: wood chen Date: Tue, 3 Dec 2024 17:59:20 +0800 Subject: [PATCH] fix(metrics): update SQLite driver usage in MetricsDB initialization - Changed the SQLite driver from "sqlite3" to "sqlite" in the NewMetricsDB function for improved compatibility with the new driver. - This change aligns with the recent dependency update to modernc.org/sqlite, enhancing performance and stability. --- internal/models/metrics.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/models/metrics.go b/internal/models/metrics.go index 1e4c7b5..d399035 100644 --- a/internal/models/metrics.go +++ b/internal/models/metrics.go @@ -46,7 +46,7 @@ type MetricsDB struct { } func NewMetricsDB(dbPath string) (*MetricsDB, error) { - db, err := sql.Open("sqlite3", dbPath) + db, err := sql.Open("sqlite", dbPath) if err != nil { return nil, err }