Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Utilizing exceptions to provide informative messages in response. #80

Open
kriiv opened this issue Jan 6, 2023 · 1 comment
Open

Utilizing exceptions to provide informative messages in response. #80

kriiv opened this issue Jan 6, 2023 · 1 comment

Comments

@kriiv
Copy link

kriiv commented Jan 6, 2023

Package has a good number of granular exceptions:

use SMTPValidateEmail\Exceptions\Exception;
use SMTPValidateEmail\Exceptions\Timeout as TimeoutException;
use SMTPValidateEmail\Exceptions\NoTimeout as NoTimeoutException;
use SMTPValidateEmail\Exceptions\NoConnection as NoConnectionException;
use SMTPValidateEmail\Exceptions\UnexpectedResponse as UnexpectedResponseException;
use SMTPValidateEmail\Exceptions\NoHelo as NoHeloException;
use SMTPValidateEmail\Exceptions\NoMailFrom as NoMailFromException;
use SMTPValidateEmail\Exceptions\NoResponse as NoResponseException;
use SMTPValidateEmail\Exceptions\SendFailed as SendFailedException;

Is there a way to utilize these exceptions to include information about the exact error that occurred and providing that as part of the $results array response?

@zytzagoo
Copy link
Owner

zytzagoo commented Jan 6, 2023

I'm not sure what exactly you want to achieve, but you should be able to extend and override the class and do whatever you need/want?

If you run into some concrete/exact/specific issue(s) while extending/overriding, do report back!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants