-
-
Notifications
You must be signed in to change notification settings - Fork 71
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
Mailer exception unification #13
Conversation
@@ -0,0 +1,12 @@ | |||
<?php | |||
/** | |||
* @author Jan Dvořák <dvorak@spinao.cz> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wrong license
* | ||
* @author David Grudl | ||
*/ | ||
class SmtpException extends SendFailedException |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dědíš to naopak, tohle je špatně, SmtpException
je obecnější
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, když teď nad tím tak přemýšlím, tak už chápu proč se to snaží udělat takhle... protože SendFailedException
může pak házet i ten sendmail...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ale pak to nemůžeš poslat v SendMailMaileru a tím to ztrácí smysl, myslel jsem, že bych v SmtpMaileru dal taky tu vyjímku SendFailed ale bude to BC break
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tak udělej interface, něco jako
class SmtpException extends \Exception {}
class SendmailException extends \Exception {}
interface SendFailedException {}
class SmtpSendFailedException extends \Exception implements SendFailedException {}
class SendmailSendFailedException extends \Exception implements SendFailedException {}
(jenom nástřel, je potřeba to domyslet)
No description provided.