From dcdf43f0fc66754efc62dd399985f4182f77ff7d Mon Sep 17 00:00:00 2001 From: Gani Georgiev Date: Sat, 27 May 2023 09:07:38 +0300 Subject: [PATCH] return conn.Exec error --- core/db_cgo.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/db_cgo.go b/core/db_cgo.go index 3375382f..c4e6303d 100644 --- a/core/db_cgo.go +++ b/core/db_cgo.go @@ -22,7 +22,7 @@ func init() { sql.Register("sqlite3_with_connect_hook", &sqlite3.SQLiteDriver{ ConnectHook: func(conn *sqlite3.SQLiteConn) error { - conn.Exec(` + _, err := conn.Exec(` PRAGMA busy_timeout = 10000; PRAGMA journal_mode = WAL; PRAGMA journal_size_limit = 200000000; @@ -30,7 +30,7 @@ func init() { PRAGMA foreign_keys = ON; `, nil) - return nil + return err }, }, )