Default database backup to same directory as database (#5250)

This commit is contained in:
WithoutPants 2024-09-11 14:02:00 +10:00 committed by GitHub
parent a17199ba21
commit 71e39e5cb8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 1 deletions

View File

@ -702,7 +702,8 @@ func (i *Config) GetBackupDirectoryPath() string {
func (i *Config) GetBackupDirectoryPathOrDefault() string {
ret := i.GetBackupDirectoryPath()
if ret == "" {
return i.GetConfigPath()
// #4915 - default to the same directory as the database
return filepath.Dir(i.GetDatabasePath())
}
return ret