From 8c4bbd946d2247c2e239cbbf8773d2d31c1a57aa Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 10 Jan 2023 11:09:30 +0100 Subject: Refactor model utils --- server/models/account/account-blocklist.ts | 2 +- server/models/account/account-video-rate.ts | 2 +- server/models/account/account.ts | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 'server/models/account') diff --git a/server/models/account/account-blocklist.ts b/server/models/account/account-blocklist.ts index 377249b38..f6212ff6e 100644 --- a/server/models/account/account-blocklist.ts +++ b/server/models/account/account-blocklist.ts @@ -6,7 +6,7 @@ import { AttributesOnly } from '@shared/typescript-utils' import { AccountBlock } from '../../../shared/models' import { ActorModel } from '../actor/actor' import { ServerModel } from '../server/server' -import { createSafeIn, getSort, searchAttribute } from '../utils' +import { createSafeIn, getSort, searchAttribute } from '../shared' import { AccountModel } from './account' @Table({ diff --git a/server/models/account/account-video-rate.ts b/server/models/account/account-video-rate.ts index 7afc907da..9e7ef4394 100644 --- a/server/models/account/account-video-rate.ts +++ b/server/models/account/account-video-rate.ts @@ -11,7 +11,7 @@ import { AttributesOnly } from '@shared/typescript-utils' import { isActivityPubUrlValid } from '../../helpers/custom-validators/activitypub/misc' import { CONSTRAINTS_FIELDS, VIDEO_RATE_TYPES } from '../../initializers/constants' import { ActorModel } from '../actor/actor' -import { getSort, throwIfNotValid } from '../utils' +import { getSort, throwIfNotValid } from '../shared' import { VideoModel } from '../video/video' import { ScopeNames as VideoChannelScopeNames, SummaryOptions, VideoChannelModel } from '../video/video-channel' import { AccountModel } from './account' diff --git a/server/models/account/account.ts b/server/models/account/account.ts index fca1b7b6d..dc989417b 100644 --- a/server/models/account/account.ts +++ b/server/models/account/account.ts @@ -16,7 +16,7 @@ import { Table, UpdatedAt } from 'sequelize-typescript' -import { ModelCache } from '@server/models/model-cache' +import { ModelCache } from '@server/models/shared/model-cache' import { AttributesOnly } from '@shared/typescript-utils' import { Account, AccountSummary } from '../../../shared/models/actors' import { isAccountDescriptionValid } from '../../helpers/custom-validators/accounts' @@ -38,7 +38,7 @@ import { ApplicationModel } from '../application/application' import { ServerModel } from '../server/server' import { ServerBlocklistModel } from '../server/server-blocklist' import { UserModel } from '../user/user' -import { buildSQLAttributes, getSort, throwIfNotValid } from '../utils' +import { buildSQLAttributes, getSort, throwIfNotValid } from '../shared' import { VideoModel } from '../video/video' import { VideoChannelModel } from '../video/video-channel' import { VideoCommentModel } from '../video/video-comment' -- cgit v1.2.3