mirror of
https://github.com/photoprism/photoprism.git
synced 2025-10-05 16:57:17 +08:00
CLI: Refactor tests and config initialization
Signed-off-by: Michael Mayer <michael@photoprism.app>
This commit is contained in:
@@ -53,12 +53,12 @@ var MigrationsCommand = cli.Command{
|
||||
|
||||
// migrationsStatusAction lists the status of schema migration.
|
||||
func migrationsStatusAction(ctx *cli.Context) error {
|
||||
conf := config.NewConfig(ctx)
|
||||
conf, err := InitConfig(ctx)
|
||||
|
||||
_, cancel := context.WithCancel(context.Background())
|
||||
defer cancel()
|
||||
|
||||
if err := conf.Init(); err != nil {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user