From 6342f4770b3caa9683aa1072f73aa658c77ff7d9 Mon Sep 17 00:00:00 2001 From: Aya Morisawa Date: Tue, 27 Aug 2019 02:44:01 +0900 Subject: [PATCH] Prevent users from changing the disabled option (#5344) --- src/client/app/common/views/components/ui/switch.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/src/client/app/common/views/components/ui/switch.vue b/src/client/app/common/views/components/ui/switch.vue index a653e9df6..8e3997ae7 100644 --- a/src/client/app/common/views/components/ui/switch.vue +++ b/src/client/app/common/views/components/ui/switch.vue @@ -49,6 +49,7 @@ export default Vue.extend({ }, methods: { toggle() { + if (this.disabled) return; this.$emit('change', !this.checked); } }