diff --git a/cmd/migrate_hydra.go b/cmd/migrate_hydra.go index 901271b17..cd9777555 100644 --- a/cmd/migrate_hydra.go +++ b/cmd/migrate_hydra.go @@ -34,7 +34,7 @@ Before running this command on an existing database, create a back up! } func init() { - RootCmd.AddCommand(migrateHydraCmd) + migrateCmd.AddCommand(migrateHydraCmd) migrateHydraCmd.Flags().Bool("read-from-env", false, "Instead of reading the database URL from the command line arguments, the value of environment variable DATABASE_URL will be used.") } diff --git a/cmd/migrate_sql.go b/cmd/migrate_sql.go index 08a9184bc..a8aaf6861 100644 --- a/cmd/migrate_sql.go +++ b/cmd/migrate_sql.go @@ -34,7 +34,7 @@ Before running this command on an existing database, create a back up! } func init() { - RootCmd.AddCommand(migrateSqlCmd) + migrateCmd.AddCommand(migrateSqlCmd) migrateSqlCmd.Flags().Bool("read-from-env", false, "Instead of reading the database URL from the command line arguments, the value of environment variable DATABASE_URL will be used.") }