Added handling for default logger if one is not specified. Fixes #1899

pull/1909/head
Jordan Wright 2020-07-17 22:14:04 -05:00
parent f2042de3bc
commit 1c5ad85de1
1 changed files with 3 additions and 0 deletions

View File

@ -55,6 +55,9 @@ func LoadConfig(filepath string) (*Config, error) {
if err != nil { if err != nil {
return nil, err return nil, err
} }
if config.Logging == nil {
config.Logging = &log.Config{}
}
// Choosing the migrations directory based on the database used. // Choosing the migrations directory based on the database used.
config.MigrationsPath = config.MigrationsPath + config.DBName config.MigrationsPath = config.MigrationsPath + config.DBName
// Explicitly set the TestFlag to false to prevent config.json overrides // Explicitly set the TestFlag to false to prevent config.json overrides