]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/commitdiff
Only list unlisted/public videos in outbox
authorChocobozzz <me@florianbigard.com>
Sun, 4 Feb 2018 22:04:32 +0000 (23:04 +0100)
committerChocobozzz <me@florianbigard.com>
Sun, 4 Feb 2018 22:04:32 +0000 (23:04 +0100)
server/models/video/video.ts

index f1b3ac169d33cdc73d45041332e62a7240543e59..ff82fb3b274adc324915e08e7657277ecf94e0b9 100644 (file)
@@ -486,7 +486,11 @@ export class VideoModel extends Model<VideoModel> {
       where: {
         id: {
           [Sequelize.Op.in]: Sequelize.literal('(' + rawQuery + ')')
-        }
+        },
+        [Sequelize.Op.or]: [
+          { privacy: VideoPrivacy.PUBLIC },
+          { privacy: VideoPrivacy.UNLISTED }
+        ]
       },
       include: [
         {