Skip to content

Commit

Permalink
Merge pull request #611 from gamahachaa/master
Browse files Browse the repository at this point in the history
Update Validator.hx
  • Loading branch information
ianharrigan authored Jul 4, 2024
2 parents 0abff41 + 04ea43c commit fd5b925
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion haxe/ui/validators/Validator.hx
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ class Validator implements IValidator {
valid = validateString(null);
case TObject:
valid = validateString(component.text);
case TClass(Date):
var stringValue:String = null;
if (component.value != null) {
stringValue = Std.string(component.value);
}
valid = validateString(stringValue);
case _:
trace("unsupported", Type.typeof(component.value), component.id, component.className, component.value);
}
Expand Down Expand Up @@ -87,4 +93,4 @@ class Validator implements IValidator {
invalidMessage = value;
}
}
}
}

0 comments on commit fd5b925

Please sign in to comment.