From 3fd3ab2d34d512b160a5e6084d7609be7b4f4452 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 12 Dec 2017 17:53:50 +0100 Subject: Move models to typescript-sequelize --- server/initializers/checker.ts | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'server/initializers/checker.ts') diff --git a/server/initializers/checker.ts b/server/initializers/checker.ts index 317d59423..7e76990b5 100644 --- a/server/initializers/checker.ts +++ b/server/initializers/checker.ts @@ -1,8 +1,8 @@ import * as config from 'config' -import { promisify0 } from '../helpers/core-utils' -import { UserModel } from '../models/account/user-interface' -import { ApplicationModel } from '../models/application/application-interface' -import { OAuthClientModel } from '../models/oauth/oauth-client-interface' +import { promisify0 } from '../helpers' +import { UserModel } from '../models/account/user' +import { ApplicationModel } from '../models/application/application' +import { OAuthClientModel } from '../models/oauth/oauth-client' // Some checks on configuration files function checkConfig () { @@ -57,22 +57,22 @@ async function checkFFmpeg (CONFIG: { TRANSCODING: { ENABLED: boolean } }) { } // We get db by param to not import it in this file (import orders) -async function clientsExist (OAuthClient: OAuthClientModel) { - const totalClients = await OAuthClient.countTotal() +async function clientsExist () { + const totalClients = await OAuthClientModel.countTotal() return totalClients !== 0 } // We get db by param to not import it in this file (import orders) -async function usersExist (User: UserModel) { - const totalUsers = await User.countTotal() +async function usersExist () { + const totalUsers = await UserModel.countTotal() return totalUsers !== 0 } // We get db by param to not import it in this file (import orders) -async function applicationExist (Application: ApplicationModel) { - const totalApplication = await Application.countTotal() +async function applicationExist () { + const totalApplication = await ApplicationModel.countTotal() return totalApplication !== 0 } -- cgit v1.2.3