Skip to content

Commit

Permalink
Merge pull request #93 from trufla-technology/make_email_not_required…
Browse files Browse the repository at this point in the history
…_failed

Check on mail validation if it's not required
  • Loading branch information
ShymaaOthman authored Mar 23, 2020
2 parents 7538dac + 9c57653 commit 13e5e56
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,8 @@ private boolean checkPattern(String originPattern) {
try {
Pattern patternObj = Pattern.compile(originPattern);
Matcher matcher = patternObj.matcher(extractData());
if (matcher.matches())

if(extractData().isEmpty() || matcher.matches())
return true;

} catch (Exception ex) {
Expand Down

0 comments on commit 13e5e56

Please sign in to comment.