Skip to content

Commit

Permalink
refactor _isValuableTextEntered
Browse files Browse the repository at this point in the history
  • Loading branch information
ksercs committed Sep 8, 2024
1 parent 8d70833 commit 48ff5cf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/devextreme/js/__internal/ui/chat/chat_message_box.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,9 @@ class MessageBox extends DOMComponent<MessageBox, Properties> {
}

_isValuableTextEntered(): boolean {
const text = this._textArea.option('text') ?? '';
return !!text.trim();
const { text } = this._textArea.option();

return !!text?.trim();
}

_renderTextArea(): void {
Expand Down

0 comments on commit 48ff5cf

Please sign in to comment.