3
0

Improve error message when database is misconfigured

This commit is contained in:
Denis Arh
2022-07-28 19:57:28 +02:00
parent 389cf7d997
commit 7d91b4eaaf
2 changed files with 2 additions and 2 deletions

View File

@@ -183,7 +183,7 @@ func connect(ctx context.Context, log *zap.Logger, isDevelopment bool, cp Connec
if conn, ok := registeredConnectors[storeType]; ok {
return conn(ctx, dsn, capabilities...)
} else {
return nil, fmt.Errorf("unknown store type used: %q (check your storage configuration)", storeType)
return nil, fmt.Errorf("unknown store type used: %q (check your database configuration)", storeType)
}
}

View File

@@ -48,7 +48,7 @@ func Connect(ctx context.Context, log *zap.Logger, dsn string, isDevelopment boo
if conn, ok := registered[storeType]; ok {
return conn(ctx, dsn)
} else {
return nil, fmt.Errorf("unknown store type used: %q (check your storage configuration)", storeType)
return nil, fmt.Errorf("unknown store type used: %q (check your database configuration)", storeType)
}
}