From dce659fa7cb2b0f814e454a7a5c6860f9c37b39e Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 10 Jan 2020 10:10:48 +0100 Subject: Fix federation when updating a video --- server/models/video/video.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/models/video/video.ts b/server/models/video/video.ts index ac8c81ddf..243871028 100644 --- a/server/models/video/video.ts +++ b/server/models/video/video.ts @@ -1802,7 +1802,9 @@ export class VideoModel extends Model { } private static isPrivacyForFederation (privacy: VideoPrivacy) { - return privacy === VideoPrivacy.PUBLIC || privacy === VideoPrivacy.UNLISTED + const castedPrivacy = parseInt(privacy + '', 10) + + return castedPrivacy === VideoPrivacy.PUBLIC || castedPrivacy === VideoPrivacy.UNLISTED } static getCategoryLabel (id: number) { -- cgit v1.2.3