diff options
author | Chocobozzz <me@florianbigard.com> | 2018-12-11 14:52:50 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-12-11 15:11:09 +0100 |
commit | 14e2014acc1362cfbb770c051a7254b156cd8efb (patch) | |
tree | 8b7d5aedd9fe0beff8b971c9bae7781ba2069228 /server/controllers/api/config.ts | |
parent | 8923187455c5aa7167d813c5c745d3857f183fd7 (diff) | |
download | PeerTube-14e2014acc1362cfbb770c051a7254b156cd8efb.tar.gz PeerTube-14e2014acc1362cfbb770c051a7254b156cd8efb.tar.zst PeerTube-14e2014acc1362cfbb770c051a7254b156cd8efb.zip |
Support additional video extensions
Diffstat (limited to 'server/controllers/api/config.ts')
-rw-r--r-- | server/controllers/api/config.ts | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/server/controllers/api/config.ts b/server/controllers/api/config.ts index d65e321e9..c75002aaf 100644 --- a/server/controllers/api/config.ts +++ b/server/controllers/api/config.ts | |||
@@ -172,7 +172,8 @@ async function updateCustomConfig (req: express.Request, res: express.Response, | |||
172 | 'instance.defaultClientRoute', | 172 | 'instance.defaultClientRoute', |
173 | 'instance.shortDescription', | 173 | 'instance.shortDescription', |
174 | 'cache.videoCaptions', | 174 | 'cache.videoCaptions', |
175 | 'signup.requiresEmailVerification' | 175 | 'signup.requiresEmailVerification', |
176 | 'transcoding.allowAdditionalExtensions' | ||
176 | ) | 177 | ) |
177 | toUpdateJSON.user['video_quota'] = toUpdate.user.videoQuota | 178 | toUpdateJSON.user['video_quota'] = toUpdate.user.videoQuota |
178 | toUpdateJSON.user['video_quota_daily'] = toUpdate.user.videoQuotaDaily | 179 | toUpdateJSON.user['video_quota_daily'] = toUpdate.user.videoQuotaDaily |
@@ -180,6 +181,7 @@ async function updateCustomConfig (req: express.Request, res: express.Response, | |||
180 | toUpdateJSON.instance['short_description'] = toUpdate.instance.shortDescription | 181 | toUpdateJSON.instance['short_description'] = toUpdate.instance.shortDescription |
181 | toUpdateJSON.instance['default_nsfw_policy'] = toUpdate.instance.defaultNSFWPolicy | 182 | toUpdateJSON.instance['default_nsfw_policy'] = toUpdate.instance.defaultNSFWPolicy |
182 | toUpdateJSON.signup['requires_email_verification'] = toUpdate.signup.requiresEmailVerification | 183 | toUpdateJSON.signup['requires_email_verification'] = toUpdate.signup.requiresEmailVerification |
184 | toUpdateJSON.transcoding['allow_additional_extensions'] = toUpdate.transcoding.allowAdditionalExtensions | ||
183 | 185 | ||
184 | await writeJSON(CONFIG.CUSTOM_FILE, toUpdateJSON, { spaces: 2 }) | 186 | await writeJSON(CONFIG.CUSTOM_FILE, toUpdateJSON, { spaces: 2 }) |
185 | 187 | ||
@@ -247,6 +249,7 @@ function customConfig (): CustomConfig { | |||
247 | }, | 249 | }, |
248 | transcoding: { | 250 | transcoding: { |
249 | enabled: CONFIG.TRANSCODING.ENABLED, | 251 | enabled: CONFIG.TRANSCODING.ENABLED, |
252 | allowAdditionalExtensions: CONFIG.TRANSCODING.ALLOW_ADDITIONAL_EXTENSIONS, | ||
250 | threads: CONFIG.TRANSCODING.THREADS, | 253 | threads: CONFIG.TRANSCODING.THREADS, |
251 | resolutions: { | 254 | resolutions: { |
252 | '240p': CONFIG.TRANSCODING.RESOLUTIONS[ '240p' ], | 255 | '240p': CONFIG.TRANSCODING.RESOLUTIONS[ '240p' ], |