diff options
author | Chocobozzz <me@florianbigard.com> | 2019-08-28 16:03:26 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-08-28 16:03:26 +0200 |
commit | 3155c8606cff211f495bf71c75c56cae85a5430f (patch) | |
tree | b44e429045bb755a1cfaa6de6d510cbf628e2d21 /server/controllers/api/videos/import.ts | |
parent | b1b7f7160b02e64dd53faea96e748dd816895495 (diff) | |
download | PeerTube-3155c8606cff211f495bf71c75c56cae85a5430f.tar.gz PeerTube-3155c8606cff211f495bf71c75c56cae85a5430f.tar.zst PeerTube-3155c8606cff211f495bf71c75c56cae85a5430f.zip |
Fix default true values when uploding videos
Diffstat (limited to 'server/controllers/api/videos/import.ts')
-rw-r--r-- | server/controllers/api/videos/import.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/controllers/api/videos/import.ts b/server/controllers/api/videos/import.ts index ebe8718c7..28ced5836 100644 --- a/server/controllers/api/videos/import.ts +++ b/server/controllers/api/videos/import.ts | |||
@@ -190,8 +190,8 @@ function buildVideo (channelId: number, body: VideoImportCreate, importData: You | |||
190 | category: body.category || importData.category, | 190 | category: body.category || importData.category, |
191 | licence: body.licence || importData.licence, | 191 | licence: body.licence || importData.licence, |
192 | language: body.language || undefined, | 192 | language: body.language || undefined, |
193 | commentsEnabled: body.commentsEnabled && true, | 193 | commentsEnabled: body.commentsEnabled !== false, // If the value is not "false", the default is "true" |
194 | downloadEnabled: body.downloadEnabled && true, | 194 | downloadEnabled: body.downloadEnabled !== false, |
195 | waitTranscoding: body.waitTranscoding || false, | 195 | waitTranscoding: body.waitTranscoding || false, |
196 | state: VideoState.TO_IMPORT, | 196 | state: VideoState.TO_IMPORT, |
197 | nsfw: body.nsfw || importData.nsfw || false, | 197 | nsfw: body.nsfw || importData.nsfw || false, |