aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/video
diff options
context:
space:
mode:
Diffstat (limited to 'server/models/video')
-rw-r--r--server/models/video/video.ts12
1 files changed, 12 insertions, 0 deletions
diff --git a/server/models/video/video.ts b/server/models/video/video.ts
index 97fdbc8ef..8c49bc3af 100644
--- a/server/models/video/video.ts
+++ b/server/models/video/video.ts
@@ -528,6 +528,18 @@ export class VideoModel extends Model<VideoModel> {
528 .findById(id, options) 528 .findById(id, options)
529 } 529 }
530 530
531 static loadByUUID (uuid: string) {
532 const options = {
533 where: {
534 uuid
535 }
536 }
537
538 return VideoModel
539 .scope([ ScopeNames.WITH_FILES ])
540 .findOne(options)
541 }
542
531 static loadByUUIDAndPopulateAccountAndServerAndTags (uuid: string) { 543 static loadByUUIDAndPopulateAccountAndServerAndTags (uuid: string) {
532 const options = { 544 const options = {
533 order: [ [ 'Tags', 'name', 'ASC' ] ], 545 order: [ [ 'Tags', 'name', 'ASC' ] ],