]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/models/redundancy/video-redundancy.ts
Add missing start and count parameters to playlist video list API endpoint documentation
[github/Chocobozzz/PeerTube.git] / server / models / redundancy / video-redundancy.ts
index 44c17f8e529878eea001a1d2879a853f1a5017c6..52997792420b6062e96c93803f6078bfe2a874d5 100644 (file)
@@ -411,7 +411,7 @@ export class VideoRedundancyModel extends Model<Partial<AttributesOnly<VideoRedu
     return VideoRedundancyModel.scope([ ScopeNames.WITH_VIDEO ]).findOne(query)
   }
 
-  static async listLocalExpired () {
+  static async listLocalExpired (): Promise<MVideoRedundancyVideo[]> {
     const actor = await getServerActor()
 
     const query = {
@@ -701,6 +701,13 @@ export class VideoRedundancyModel extends Model<Partial<AttributesOnly<VideoRedu
     return undefined
   }
 
+  getVideoUUID () {
+    const video = this.getVideo()
+    if (!video) return undefined
+
+    return video.uuid
+  }
+
   isOwned () {
     return !!this.strategy
   }