MattKetmo / EmailChecker

Disposable email detection library for PHP
MIT License
264 stars 79 forks source link

Allow to override message when using attributes #93

Closed VincentLanglet closed 7 months ago

VincentLanglet commented 7 months ago

Hi @MattKetmo

This allows to write

#[NotThrowawayEmail(message: 'user.message.error.invalid_email_domain')]

when using the constraint as an attribute.

This is similar to Symfony constraint: https://github.com/symfony/symfony/blob/7.1/src/Symfony/Component/Validator/Constraints/Email.php#L48