aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-10-14 11:35:43 +0200
committerChocobozzz <me@florianbigard.com>2021-10-14 11:35:43 +0200
commitcf0c8ee588e37809d85ec1deec1e4fdfa0f122a5 (patch)
tree1692868027592d2a300988643fdd96e5fdfe2091 /client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
parente1a570abff3ebf375433e58e7362d56bd32d4cd8 (diff)
downloadPeerTube-cf0c8ee588e37809d85ec1deec1e4fdfa0f122a5.tar.gz
PeerTube-cf0c8ee588e37809d85ec1deec1e4fdfa0f122a5.tar.zst
PeerTube-cf0c8ee588e37809d85ec1deec1e4fdfa0f122a5.zip
Fix admin edition disabling feature
Diffstat (limited to 'client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts')
-rw-r--r--client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts7
1 files changed, 6 insertions, 1 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 04b0175a7..96c67fac7 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
@@ -258,7 +258,8 @@ export class EditCustomConfigComponent extends FormReactive implements OnInit {
258 258
259 this.loadConfigAndUpdateForm() 259 this.loadConfigAndUpdateForm()
260 this.loadCategoriesAndLanguages() 260 this.loadCategoriesAndLanguages()
261 if (!this.serverConfig.allowEdits) { 261
262 if (!this.isUpdateAllowed()) {
262 this.form.disable() 263 this.form.disable()
263 } 264 }
264 } 265 }
@@ -293,6 +294,10 @@ export class EditCustomConfigComponent extends FormReactive implements OnInit {
293 }) 294 })
294 } 295 }
295 296
297 isUpdateAllowed () {
298 return this.serverConfig.webadmin.configuration.edition.allowed === true
299 }
300
296 hasConsistentOptions () { 301 hasConsistentOptions () {
297 if (this.hasLiveAllowReplayConsistentOptions()) return true 302 if (this.hasLiveAllowReplayConsistentOptions()) return true
298 303