From 6a5a21b4e1aa5ea11fba98cc922c700208e927ad Mon Sep 17 00:00:00 2001 From: besserwisser Date: Wed, 19 Jan 2022 12:02:45 +0100 Subject: [PATCH] Fix undefined access on checkbox group Trying to access the checkbox group with having one results in an error. The undefined check prevents the error. --- packages/checkbox/src/checkbox.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/checkbox/src/checkbox.vue b/packages/checkbox/src/checkbox.vue index 00df69e99..08cd31c43 100644 --- a/packages/checkbox/src/checkbox.vue +++ b/packages/checkbox/src/checkbox.vue @@ -137,6 +137,7 @@ /* used to make the isDisabled judgment under max/min props */ isLimitDisabled() { + if (!this._checkboxGroup) return true; const { max, min } = this._checkboxGroup; return !!(max || min) && (this.model.length >= max && !this.isChecked) ||