Skip to content

Commit 60f441a

Browse files
committed
Fix placeholder check for dirty state
1 parent b848826 commit 60f441a

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/textfield/textfield.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -175,10 +175,9 @@
175175
* @public
176176
*/
177177
MaterialTextfield.prototype.checkDirty = function() {
178-
var placeholder = this.input_.placeholder;
179178
if (
180179
(this.input_.value && this.input_.value.length > 0) ||
181-
(placeholder !== undefined || placeholder.trim() !== "")
180+
(this.input_.placeholder.trim() !== '')
182181
) {
183182
this.element_.classList.add(this.CssClasses_.IS_DIRTY);
184183
} else {

0 commit comments

Comments
 (0)