From 8ea445d3bca51f6d4b04231e632b112b4cfa01bb Mon Sep 17 00:00:00 2001 From: Serhii Kulykov Date: Sun, 3 Oct 2021 12:28:54 +0300 Subject: [PATCH] fix: use hasHelperText --- packages/field-base/src/field-mixin.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/packages/field-base/src/field-mixin.js b/packages/field-base/src/field-mixin.js index 6abbe96115..125983d4c8 100644 --- a/packages/field-base/src/field-mixin.js +++ b/packages/field-base/src/field-mixin.js @@ -261,19 +261,18 @@ export const FieldMixin = (superclass) => _helperTextChanged(helperText) { let helper = this._helperNode; - const hasHelper = this.__isNotEmpty(helperText); + const hasHelperText = this.__isNotEmpty(helperText); if (hasHelperText && !helper) { // Create helper lazily helper = this.__attachDefaultHelper(); } - } // Only set text content for default helper if (helper && helper === this.__defaultHelper) { helper.textContent = helperText; } - this.__toggleHasHelper(hasHelper); + this.__toggleHasHelper(hasHelperText); } /** @protected */