Allow more absolute paths in Config

This commit is contained in:
2023-04-16 11:11:01 +02:00
parent 52e65ac1ed
commit d5b9af541f

View File

@ -23,7 +23,7 @@ namespace Elwig.Helpers {
if (ini == null || !ini.TryGetKey("database.file", out string db)) {
DatabaseFile = App.DataPath + "database.sqlite3";
} else if (db.Length > 1 && db[1] == ':') {
} else if (db.Length > 1 && (db[1] == ':' || db[0] == '/' || db[0] == '\\')) {
DatabaseFile = db;
} else {
DatabaseFile = App.DataPath + db;