kaisellgren / mailer

Compose and send emails from Dart. Supports file attachments, HTML emails and multiple transport methods.
MIT License
166 stars 86 forks source link

To address validation exception throws FROM_ADDRESS_EMPTY code #255

Closed amugofjava closed 1 month ago

amugofjava commented 1 month ago

Hi,

Firstly, thank you for this great library - it really makes sending emails from Dart & Flutter so much easier.

There is, I believe, a minor issue in the validator. If a recipient address is not provided, the validator flags the error but returns the code FROM_ADDRESS_EMPTY. This makes it a bit confusing. Can we have a code TO_ADDRESS_EMPTY for this type of error?

Thanks.