From 2b4dd7e26d93c2d9bef4f365cb03c511eff4ca8f Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 25 Apr 2019 13:55:28 +0200 Subject: Fix optional privacy in upload endpoint --- server/controllers/api/videos/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'server/controllers/api') diff --git a/server/controllers/api/videos/index.ts b/server/controllers/api/videos/index.ts index 5bbce11b4..1a18a8ae8 100644 --- a/server/controllers/api/videos/index.ts +++ b/server/controllers/api/videos/index.ts @@ -182,7 +182,7 @@ async function addVideo (req: express.Request, res: express.Response) { nsfw: videoInfo.nsfw || false, description: videoInfo.description, support: videoInfo.support, - privacy: videoInfo.privacy, + privacy: videoInfo.privacy || VideoPrivacy.PRIVATE, duration: videoPhysicalFile['duration'], // duration was added by a previous middleware channelId: res.locals.videoChannel.id, originallyPublishedAt: videoInfo.originallyPublishedAt -- cgit v1.2.3