diff --git a/src/chart/helper/whiskerBoxCommon.ts b/src/chart/helper/whiskerBoxCommon.ts index 9502d3b6f8..efd425afa4 100644 --- a/src/chart/helper/whiskerBoxCommon.ts +++ b/src/chart/helper/whiskerBoxCommon.ts @@ -57,10 +57,7 @@ class WhiskerBoxCommonMixin { */ _hasEncodeRule(key: string) { const encodeRules = this.getEncode(); - if (encodeRules && encodeRules.data && encodeRules.data.has(key)) { - return encodeRules.data.get(key) != null; - } - return false; + return encodeRules && encodeRules.get(key) != null; } /**