aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/video/sql
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-08-17 14:52:23 +0200
committerChocobozzz <me@florianbigard.com>2022-08-17 14:54:01 +0200
commit2ec349aa857b0bd8f26de5cd78981d60c9b98a69 (patch)
treec48e4957d0abb778ee5eaa2474c24a9c88f69260 /server/models/video/sql
parent396f6f0140b0f76162e2378fd5a61e2f888673ed (diff)
downloadPeerTube-2ec349aa857b0bd8f26de5cd78981d60c9b98a69.tar.gz
PeerTube-2ec349aa857b0bd8f26de5cd78981d60c9b98a69.tar.zst
PeerTube-2ec349aa857b0bd8f26de5cd78981d60c9b98a69.zip
Prefer using our pick function
Diffstat (limited to 'server/models/video/sql')
-rw-r--r--server/models/video/sql/video/video-model-get-query-builder.ts2
-rw-r--r--server/models/video/sql/video/videos-id-list-query-builder.ts5
-rw-r--r--server/models/video/sql/video/videos-model-list-query-builder.ts2
3 files changed, 6 insertions, 3 deletions
diff --git a/server/models/video/sql/video/video-model-get-query-builder.ts b/server/models/video/sql/video/video-model-get-query-builder.ts
index 29e59c8be..8e90ff641 100644
--- a/server/models/video/sql/video/video-model-get-query-builder.ts
+++ b/server/models/video/sql/video/video-model-get-query-builder.ts
@@ -1,5 +1,5 @@
1import { pick } from 'lodash'
2import { Sequelize, Transaction } from 'sequelize' 1import { Sequelize, Transaction } from 'sequelize'
2import { pick } from '@shared/core-utils'
3import { AbstractVideoQueryBuilder } from './shared/abstract-video-query-builder' 3import { AbstractVideoQueryBuilder } from './shared/abstract-video-query-builder'
4import { VideoFileQueryBuilder } from './shared/video-file-query-builder' 4import { VideoFileQueryBuilder } from './shared/video-file-query-builder'
5import { VideoModelBuilder } from './shared/video-model-builder' 5import { VideoModelBuilder } from './shared/video-model-builder'
diff --git a/server/models/video/sql/video/videos-id-list-query-builder.ts b/server/models/video/sql/video/videos-id-list-query-builder.ts
index 8692a436a..14f903851 100644
--- a/server/models/video/sql/video/videos-id-list-query-builder.ts
+++ b/server/models/video/sql/video/videos-id-list-query-builder.ts
@@ -1,4 +1,4 @@
1import { Sequelize } from 'sequelize' 1import { Sequelize, Transaction } from 'sequelize'
2import validator from 'validator' 2import validator from 'validator'
3import { exists } from '@server/helpers/custom-validators/misc' 3import { exists } from '@server/helpers/custom-validators/misc'
4import { WEBSERVER } from '@server/initializers/constants' 4import { WEBSERVER } from '@server/initializers/constants'
@@ -73,6 +73,9 @@ export type BuildVideosListQueryOptions = {
73 73
74 group?: string 74 group?: string
75 having?: string 75 having?: string
76
77 transaction?: Transaction
78 logging?: boolean
76} 79}
77 80
78export class VideosIdListQueryBuilder extends AbstractRunQuery { 81export class VideosIdListQueryBuilder extends AbstractRunQuery {
diff --git a/server/models/video/sql/video/videos-model-list-query-builder.ts b/server/models/video/sql/video/videos-model-list-query-builder.ts
index 4fe6bc321..3fdac4ed3 100644
--- a/server/models/video/sql/video/videos-model-list-query-builder.ts
+++ b/server/models/video/sql/video/videos-model-list-query-builder.ts
@@ -1,5 +1,5 @@
1import { pick } from 'lodash'
2import { Sequelize } from 'sequelize' 1import { Sequelize } from 'sequelize'
2import { pick } from '@shared/core-utils'
3import { VideoInclude } from '@shared/models' 3import { VideoInclude } from '@shared/models'
4import { AbstractVideoQueryBuilder } from './shared/abstract-video-query-builder' 4import { AbstractVideoQueryBuilder } from './shared/abstract-video-query-builder'
5import { VideoFileQueryBuilder } from './shared/video-file-query-builder' 5import { VideoFileQueryBuilder } from './shared/video-file-query-builder'