aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/video/video.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-06-08 17:29:45 +0200
committerChocobozzz <me@florianbigard.com>2021-06-08 17:41:48 +0200
commit28dfb44b145c537aba07ae73cb1287f25532022a (patch)
tree4aee64a049b396c8689f29e5ca8a8094dd3baf54 /server/models/video/video.ts
parent75e12406e271e3aaf1f7c394a63ce570091db480 (diff)
downloadPeerTube-28dfb44b145c537aba07ae73cb1287f25532022a.tar.gz
PeerTube-28dfb44b145c537aba07ae73cb1287f25532022a.tar.zst
PeerTube-28dfb44b145c537aba07ae73cb1287f25532022a.zip
Try to speed up AP update transaction
Diffstat (limited to 'server/models/video/video.ts')
-rw-r--r--server/models/video/video.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/server/models/video/video.ts b/server/models/video/video.ts
index 8f561116b..44aaa24ef 100644
--- a/server/models/video/video.ts
+++ b/server/models/video/video.ts
@@ -1886,7 +1886,7 @@ export class VideoModel extends Model<Partial<AttributesOnly<VideoModel>>> {
1886 return Array.isArray(this.VideoFiles) === true && this.VideoFiles.length !== 0 1886 return Array.isArray(this.VideoFiles) === true && this.VideoFiles.length !== 0
1887 } 1887 }
1888 1888
1889 async addAndSaveThumbnail (thumbnail: MThumbnail, transaction: Transaction) { 1889 async addAndSaveThumbnail (thumbnail: MThumbnail, transaction?: Transaction) {
1890 thumbnail.videoId = this.id 1890 thumbnail.videoId = this.id
1891 1891
1892 const savedThumbnail = await thumbnail.save({ transaction }) 1892 const savedThumbnail = await thumbnail.save({ transaction })