fixed the empty string always pass trough the validator