postgres working

This commit is contained in:
afeiszli
2021-10-08 13:11:31 -04:00
parent 638e139389
commit b61d415e9d
7 changed files with 223 additions and 2 deletions
+2 -2
View File
@@ -82,9 +82,9 @@ func GetVersion() string {
}
func GetDB() string {
database := "sqlite"
if os.Getenv("DATABASE") == "rqlite" {
if os.Getenv("DATABASE") != "" {
database = os.Getenv("DATABASE")
} else if config.Config.Server.Database == "rqlite" {
} else if config.Config.Server.Database != "" {
database = config.Config.Server.Database
}
return database