micronaut-projects / micronaut-core

Micronaut Application Framework
http://micronaut.io
Apache License 2.0
6.09k stars 1.07k forks source link

`EmailValidator` not working properly #6890

Closed roma0297 closed 2 years ago

roma0297 commented 2 years ago

Expected Behavior

I expect that email email@gmail won't pass the validation

Actual Behaviour

Email email@gmail Is passing the validation

Steps To Reproduce

  1. Create a simple application with @Post controller
  2. Add @Email annotation to one of the string fields in the request body
  3. Pass an email email@gmail to the request

Environment Information

No response

Example Application

No response

Version

3.3.0

bseitkazin commented 2 years ago

I think you are using @Email from javax.validation.constraints.Email? So, it is not an issue of the Micronaut framework, according to the answer on StackOverflow, the email@gmail is a valid email.

Link - https://stackoverflow.com/questions/50535214/javax-validation-constraints-email-matching-invalid-email-address