aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/abuse
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-12-16 18:04:16 +0100
committerChocobozzz <me@florianbigard.com>2021-12-16 18:04:16 +0100
commit6b5f72beda96d8b7e4d6329c4001827334de27dd (patch)
tree1c14354896ce1d44b373f18f9ae0dfc72e0b12df /server/models/abuse
parent077f344891b3f4b00a8a4f8d700306d4392b3a2f (diff)
downloadPeerTube-6b5f72beda96d8b7e4d6329c4001827334de27dd.tar.gz
PeerTube-6b5f72beda96d8b7e4d6329c4001827334de27dd.tar.zst
PeerTube-6b5f72beda96d8b7e4d6329c4001827334de27dd.zip
Move typescript utils in its own directory
Diffstat (limited to 'server/models/abuse')
-rw-r--r--server/models/abuse/abuse-message.ts2
-rw-r--r--server/models/abuse/abuse.ts3
-rw-r--r--server/models/abuse/video-abuse.ts2
-rw-r--r--server/models/abuse/video-comment-abuse.ts2
4 files changed, 5 insertions, 4 deletions
diff --git a/server/models/abuse/abuse-message.ts b/server/models/abuse/abuse-message.ts
index 2c5987e96..6a441a210 100644
--- a/server/models/abuse/abuse-message.ts
+++ b/server/models/abuse/abuse-message.ts
@@ -1,7 +1,7 @@
1import { AllowNull, BelongsTo, Column, CreatedAt, DataType, ForeignKey, Is, Model, Table, UpdatedAt } from 'sequelize-typescript' 1import { AllowNull, BelongsTo, Column, CreatedAt, DataType, ForeignKey, Is, Model, Table, UpdatedAt } from 'sequelize-typescript'
2import { isAbuseMessageValid } from '@server/helpers/custom-validators/abuses' 2import { isAbuseMessageValid } from '@server/helpers/custom-validators/abuses'
3import { MAbuseMessage, MAbuseMessageFormattable } from '@server/types/models' 3import { MAbuseMessage, MAbuseMessageFormattable } from '@server/types/models'
4import { AttributesOnly } from '@shared/core-utils' 4import { AttributesOnly } from '@shared/typescript-utils'
5import { AbuseMessage } from '@shared/models' 5import { AbuseMessage } from '@shared/models'
6import { AccountModel, ScopeNames as AccountScopeNames } from '../account/account' 6import { AccountModel, ScopeNames as AccountScopeNames } from '../account/account'
7import { getSort, throwIfNotValid } from '../utils' 7import { getSort, throwIfNotValid } from '../utils'
diff --git a/server/models/abuse/abuse.ts b/server/models/abuse/abuse.ts
index 3518f5c02..4344df006 100644
--- a/server/models/abuse/abuse.ts
+++ b/server/models/abuse/abuse.ts
@@ -16,7 +16,7 @@ import {
16 UpdatedAt 16 UpdatedAt
17} from 'sequelize-typescript' 17} from 'sequelize-typescript'
18import { isAbuseModerationCommentValid, isAbuseReasonValid, isAbuseStateValid } from '@server/helpers/custom-validators/abuses' 18import { isAbuseModerationCommentValid, isAbuseReasonValid, isAbuseStateValid } from '@server/helpers/custom-validators/abuses'
19import { abusePredefinedReasonsMap, AttributesOnly } from '@shared/core-utils' 19import { abusePredefinedReasonsMap } from '@shared/core-utils'
20import { 20import {
21 AbuseFilter, 21 AbuseFilter,
22 AbuseObject, 22 AbuseObject,
@@ -30,6 +30,7 @@ import {
30 UserAbuse, 30 UserAbuse,
31 UserVideoAbuse 31 UserVideoAbuse
32} from '@shared/models' 32} from '@shared/models'
33import { AttributesOnly } from '@shared/typescript-utils'
33import { ABUSE_STATES, CONSTRAINTS_FIELDS } from '../../initializers/constants' 34import { ABUSE_STATES, CONSTRAINTS_FIELDS } from '../../initializers/constants'
34import { MAbuseAdminFormattable, MAbuseAP, MAbuseFull, MAbuseReporter, MAbuseUserFormattable, MUserAccountId } from '../../types/models' 35import { MAbuseAdminFormattable, MAbuseAP, MAbuseFull, MAbuseReporter, MAbuseUserFormattable, MUserAccountId } from '../../types/models'
35import { AccountModel, ScopeNames as AccountScopeNames, SummaryOptions as AccountSummaryOptions } from '../account/account' 36import { AccountModel, ScopeNames as AccountScopeNames, SummaryOptions as AccountSummaryOptions } from '../account/account'
diff --git a/server/models/abuse/video-abuse.ts b/server/models/abuse/video-abuse.ts
index 95bff50d0..773a9ebba 100644
--- a/server/models/abuse/video-abuse.ts
+++ b/server/models/abuse/video-abuse.ts
@@ -1,5 +1,5 @@
1import { AllowNull, BelongsTo, Column, CreatedAt, DataType, Default, ForeignKey, Model, Table, UpdatedAt } from 'sequelize-typescript' 1import { AllowNull, BelongsTo, Column, CreatedAt, DataType, Default, ForeignKey, Model, Table, UpdatedAt } from 'sequelize-typescript'
2import { AttributesOnly } from '@shared/core-utils' 2import { AttributesOnly } from '@shared/typescript-utils'
3import { VideoDetails } from '@shared/models' 3import { VideoDetails } from '@shared/models'
4import { VideoModel } from '../video/video' 4import { VideoModel } from '../video/video'
5import { AbuseModel } from './abuse' 5import { AbuseModel } from './abuse'
diff --git a/server/models/abuse/video-comment-abuse.ts b/server/models/abuse/video-comment-abuse.ts
index 32cb2ca64..337aaaa58 100644
--- a/server/models/abuse/video-comment-abuse.ts
+++ b/server/models/abuse/video-comment-abuse.ts
@@ -1,5 +1,5 @@
1import { BelongsTo, Column, CreatedAt, ForeignKey, Model, Table, UpdatedAt } from 'sequelize-typescript' 1import { BelongsTo, Column, CreatedAt, ForeignKey, Model, Table, UpdatedAt } from 'sequelize-typescript'
2import { AttributesOnly } from '@shared/core-utils' 2import { AttributesOnly } from '@shared/typescript-utils'
3import { VideoCommentModel } from '../video/video-comment' 3import { VideoCommentModel } from '../video/video-comment'
4import { AbuseModel } from './abuse' 4import { AbuseModel } from './abuse'
5 5