aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+admin
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-11-10 14:15:59 +0100
committerChocobozzz <me@florianbigard.com>2020-11-10 14:15:59 +0100
commit210856a7be4631540791bad027fb3ef0f7a51f14 (patch)
treedb187b29a37fb1cfba1c7f97efb8a145b1f1a149 /client/src/app/+admin
parent52a350a15c34aa13bffaeedeb39de37cb0534fde (diff)
downloadPeerTube-210856a7be4631540791bad027fb3ef0f7a51f14.tar.gz
PeerTube-210856a7be4631540791bad027fb3ef0f7a51f14.tar.zst
PeerTube-210856a7be4631540791bad027fb3ef0f7a51f14.zip
Try to fix live segments check
Diffstat (limited to 'client/src/app/+admin')
-rw-r--r--client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts10
1 files changed, 8 insertions, 2 deletions
diff --git a/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts b/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
index de1cf46b1..d442df0e3 100644
--- a/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
+++ b/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
@@ -95,7 +95,7 @@ export class EditCustomConfigComponent extends FormReactive implements OnInit, A
95 ] 95 ]
96 96
97 this.liveMaxDurationOptions = [ 97 this.liveMaxDurationOptions = [
98 { value: 0, label: $localize`No limit` }, 98 { value: null, label: $localize`No limit` },
99 { value: 1000 * 3600, label: $localize`1 hour` }, 99 { value: 1000 * 3600, label: $localize`1 hour` },
100 { value: 1000 * 3600 * 3, label: $localize`3 hours` }, 100 { value: 1000 * 3600 * 3, label: $localize`3 hours` },
101 { value: 1000 * 3600 * 5, label: $localize`5 hours` }, 101 { value: 1000 * 3600 * 5, label: $localize`5 hours` },
@@ -328,7 +328,13 @@ export class EditCustomConfigComponent extends FormReactive implements OnInit, A
328 } 328 }
329 329
330 async formValidated () { 330 async formValidated () {
331 this.configService.updateCustomConfig(this.form.getRawValue()) 331 const value: CustomConfig = this.form.getRawValue()
332
333 // Transform "null" to null
334 const maxDuration = value.live.maxDuration as any
335 if (maxDuration === 'null') value.live.maxDuration = null
336
337 this.configService.updateCustomConfig(value)
332 .subscribe( 338 .subscribe(
333 res => { 339 res => {
334 this.customConfig = res 340 this.customConfig = res