diff --git a/switchery.js b/switchery.js index baa4c6b..083da3f 100644 --- a/switchery.js +++ b/switchery.js @@ -376,9 +376,9 @@ Switchery.prototype.enable = function() { */ Switchery.prototype.disable = function() { - if (this.options.disabled) this.options.disabled = true; - if (this.element.disabled) this.element.disabled = true; - if (this.element.readOnly) this.element.readOnly = true; + if (!this.options.disabled) this.options.disabled = true; + if (!this.element.disabled) this.element.disabled = true; + if (!this.element.readOnly) this.element.readOnly = true; this.switcher.style.opacity = this.options.disabledOpacity; this.destroy(); };