Skip to content

Commit

Permalink
Refs #10652: Aschroder_SMTPPro_Model_Email_Queue - fix queue send met…
Browse files Browse the repository at this point in the history
…hod to continue sending

						   and mark mail as processed if non protocol error occurs
	     Aschroder SMTPPro - fix admin module configuration file to allow multi store configuration
  • Loading branch information
d-kochnov-optimus committed Mar 29, 2017
1 parent a9f5bc2 commit 03ff848
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 22 deletions.
10 changes: 9 additions & 1 deletion app/code/local/Aschroder/SMTPPro/Model/Email/Queue.php
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,15 @@ public function send()
Mage::logException($e);
Mage::setIsDeveloperMode($oldDevMode);

return false;
// 553 - Requested action not taken: mailbox name not allowed
if ($e instanceof Zend_Mail_Protocol_Exception && $e->getCode() != 553) {
return false;
}

$message->setProcessedAt(Varien_Date::formatDate(true));
$message->save();

continue;
}

// after each valid message has been sent - pause if required
Expand Down
42 changes: 21 additions & 21 deletions app/code/local/Aschroder/SMTPPro/etc/system.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
<label>Aschroder Extensions</label>
<sort_order>600</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>0</show_in_website>
<show_in_store>0</show_in_store>
<show_in_website>1</show_in_website>
<show_in_store>1</show_in_store>
</aschroder>
</tabs>
<sections>
Expand All @@ -17,16 +17,16 @@
<frontend_type>text</frontend_type>
<sort_order>110</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>0</show_in_website>
<show_in_store>0</show_in_store>
<show_in_website>1</show_in_website>
<show_in_store>1</show_in_store>
<groups>
<general module="smtppro" translate="label comment">
<label>General Settings</label>
<frontend_type>text</frontend_type>
<sort_order>10</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<comment><![CDATA[<div style='background-color: #efefef;margin-bottom: 10px;height: 40px;'> <img style='float:left;width: 150px;' src='http://www.aschroder.com/smtppro-logo.png' /> <span style='float:left;font-size: 20px; margin:10px;'>SMTP Pro Email Extension</span> </div> Configure your SMTP connection below. If you have any questions or would like any help please visit <a href='http://magesmtppro.com' target='_blank'>magesmtppro.com</a>.]]></comment>
<fields>
<option translate="label">
Expand All @@ -35,8 +35,8 @@
<source_model>smtppro/system_config_source_smtp_option</source_model>
<sort_order>10</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>0</show_in_website>
<show_in_store>0</show_in_store>
<show_in_website>1</show_in_website>
<show_in_store>1</show_in_store>
</option>


Expand All @@ -47,7 +47,7 @@
<sort_order>20</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>google</option></depends>
</googleapps_email>
<googleapps_gpassword translate="label comment">
Expand All @@ -58,7 +58,7 @@
<sort_order>23</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>google</option></depends>
</googleapps_gpassword>

Expand All @@ -68,7 +68,7 @@
<sort_order>20</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>sendgrid</option></depends>
</sendgrid_email>
<sendgrid_password translate="label comment">
Expand All @@ -79,7 +79,7 @@
<sort_order>23</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>sendgrid</option></depends>
</sendgrid_password>

Expand All @@ -89,7 +89,7 @@
<sort_order>20</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>mailup</option></depends>
</mailup_email>
<mailup_password translate="label comment">
Expand All @@ -100,7 +100,7 @@
<sort_order>23</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>mailup</option></depends>
</mailup_password>

Expand All @@ -112,7 +112,7 @@
<sort_order>20</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>ses</option></depends>
</ses_access_key>
<ses_private_key translate="label comment">
Expand All @@ -123,7 +123,7 @@
<sort_order>23</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>ses</option></depends>
</ses_private_key>

Expand All @@ -134,7 +134,7 @@
<sort_order>20</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>smtp</option></depends>
</smtp_authentication>
<smtp_username translate="label">
Expand All @@ -143,7 +143,7 @@
<sort_order>23</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>smtp</option><smtp_authentication separator=",">login,plain,crammd5</smtp_authentication></depends>
</smtp_username>
<smtp_password translate="label">
Expand All @@ -153,7 +153,7 @@
<sort_order>26</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>smtp</option><smtp_authentication separator=",">login,plain,crammd5</smtp_authentication></depends>
</smtp_password>
<smtp_host translate="label">
Expand All @@ -162,7 +162,7 @@
<sort_order>29</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>smtp</option></depends>
</smtp_host>
<smtp_port translate="label">
Expand All @@ -171,7 +171,7 @@
<sort_order>32</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>smtp</option></depends>
</smtp_port>
<smtp_ssl translate="label comment">
Expand All @@ -182,7 +182,7 @@
<sort_order>35</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
<show_in_store>1</show_in_store>
<depends><option>smtp</option></depends>
</smtp_ssl>

Expand Down

0 comments on commit 03ff848

Please sign in to comment.