mirror of https://github.com/Xhofe/alist
fix: cancel `EXCLUSIVE` mode on sqlite3
because it will result in failure to get admin's infopull/3117/head
parent
ce4a295008
commit
98872a8fdb
|
@ -51,7 +51,7 @@ func InitDB() {
|
||||||
if !(strings.HasSuffix(database.DBFile, ".db") && len(database.DBFile) > 3) {
|
if !(strings.HasSuffix(database.DBFile, ".db") && len(database.DBFile) > 3) {
|
||||||
log.Fatalf("db name error.")
|
log.Fatalf("db name error.")
|
||||||
}
|
}
|
||||||
dB, err = gorm.Open(sqlite.Open(fmt.Sprintf("%s?_journal=WAL&_locking=EXCLUSIVE&_vacuum=incremental",
|
dB, err = gorm.Open(sqlite.Open(fmt.Sprintf("%s?_journal=WAL&_vacuum=incremental",
|
||||||
database.DBFile)), gormConfig)
|
database.DBFile)), gormConfig)
|
||||||
}
|
}
|
||||||
case "mysql":
|
case "mysql":
|
||||||
|
|
Loading…
Reference in New Issue