X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=scripts%2Freset-password.ts;h=bf6535cea85e1329e318b2a0ec67622bc0a82d35;hb=f0af38e69677d1afe17e48b3f5267128db3db1a4;hp=6126c3cd09fa9da04c57b1c52852ad3196627f66;hpb=2aaa1a3fdc49be77aec5309dab5507865c38d392;p=github%2FChocobozzz%2FPeerTube.git diff --git a/scripts/reset-password.ts b/scripts/reset-password.ts index 6126c3cd0..bf6535cea 100755 --- a/scripts/reset-password.ts +++ b/scripts/reset-password.ts @@ -2,7 +2,7 @@ import { registerTSPaths } from '../server/helpers/register-ts-paths' registerTSPaths() import * as program from 'commander' -import { initDatabaseModels } from '../server/initializers' +import { initDatabaseModels } from '../server/initializers/database' import { UserModel } from '../server/models/account/user' import { isUserPasswordValid } from '../server/helpers/custom-validators/users' @@ -53,3 +53,7 @@ initDatabaseModels(true) .finally(() => process.exit(0)) }) }) + .catch(err => { + console.error(err) + process.exit(-1) + })