Post SMTP Mailer/Email Log - Version 1.7.10

Version Description

  • 2017-11-21 ==
  • Fixed: bug while detecting transcript error
Download this release

Release Info

Developer yehudah
Plugin Icon 128x128 Post SMTP Mailer/Email Log
Version 1.7.10
Comparing to
See all releases

Code changes from version 1.7.9 to 1.7.10

Postman/Postman-Email-Log/PostmanEmailLogService.php CHANGED
@@ -156,12 +156,18 @@ if ( ! class_exists( 'PostmanEmailLogService' ) ) {
156
  }
157
 
158
  private function checkForLogErrors( PostmanEmailLog $log ) {
 
 
 
 
159
  if ( $log->statusMessage && ! empty( $log->statusMessage ) ) {
160
- mail( get_bloginfo( 'admin_email' ), __( 'Post SMTP email error', Postman::TEXT_DOMAIN ), $log->statusMessage );
161
  }
162
 
163
- if ( strpos( strtolower( $log->sessionTranscript ), 'error' ) !== false ) {
164
- mail( get_bloginfo( 'admin_email' ), __( 'Post SMTP session transcript error', Postman::TEXT_DOMAIN ), $log->sessionTranscript );
 
 
165
  }
166
  }
167
 
156
  }
157
 
158
  private function checkForLogErrors( PostmanEmailLog $log ) {
159
+ $message = __( 'You getting this message because an error detected while delivered your email.', Postman::TEXT_DOMAIN );
160
+ $message .= "\r\n" . __( 'You are welcome to post a support issue.', Postman::TEXT_DOMAIN );
161
+ $message .= "\r\n" . __( 'The log to paste with your support issue:', Postman::TEXT_DOMAIN ) . "\r\n";
162
+
163
  if ( $log->statusMessage && ! empty( $log->statusMessage ) ) {
164
+ mail( get_bloginfo( 'admin_email' ), __( 'Post SMTP email error', Postman::TEXT_DOMAIN ), $message . $log->statusMessage );
165
  }
166
 
167
+ preg_match_all( '/(.*)From/s', $log->sessionTranscript, $matches );
168
+
169
+ if ( isset( $matches[1][0] ) && ! empty( $matches[1][0] ) && strpos( strtolower( $matches[1][0] ), 'error' ) !== false ) {
170
+ mail( get_bloginfo( 'admin_email' ), __( 'Post SMTP session transcript error', Postman::TEXT_DOMAIN ), $message . $log->sessionTranscript );
171
  }
172
  }
173
 
postman-smtp.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin Name: Post SMTP
5
  * Plugin URI: https://wordpress.org/plugins/post-smtp/
6
  * Description: Email not reliable? Post SMTP is the first and only WordPress SMTP plugin to implement OAuth 2.0 for Gmail, Hotmail and Yahoo Mail. Setup is a breeze with the Configuration Wizard and integrated Port Tester. Enjoy worry-free delivery even if your password changes!
7
- * Version: 1.7.9
8
  * Author: Jason Hendriks, Yehuda Hassine
9
  * Text Domain: post-smtp
10
  * Author URI: https://postmansmtp.com
@@ -71,5 +71,5 @@ function post_start( $startingMemory ) {
71
  */
72
  function post_setupPostman() {
73
  require_once 'Postman/Postman.php';
74
- $kevinCostner = new Postman( __FILE__, '1.7.9' );
75
  }
4
  * Plugin Name: Post SMTP
5
  * Plugin URI: https://wordpress.org/plugins/post-smtp/
6
  * Description: Email not reliable? Post SMTP is the first and only WordPress SMTP plugin to implement OAuth 2.0 for Gmail, Hotmail and Yahoo Mail. Setup is a breeze with the Configuration Wizard and integrated Port Tester. Enjoy worry-free delivery even if your password changes!
7
+ * Version: 1.7.10
8
  * Author: Jason Hendriks, Yehuda Hassine
9
  * Text Domain: post-smtp
10
  * Author URI: https://postmansmtp.com
71
  */
72
  function post_setupPostman() {
73
  require_once 'Postman/Postman.php';
74
+ $kevinCostner = new Postman( __FILE__, '1.7.10' );
75
  }
readme.txt CHANGED
@@ -1,9 +1,10 @@
1
  === Post SMTP Mailer/Email Log ===
2
  Contributors: yehudah, jasonhendriks
3
- Tags: postman smtp, postman, smtp, email, mail, mailer, email log, oauth2, gmail, google apps, hotmail, yahoo, mandrill api, sendgrid api, elastic email
 
4
  Requires at least: 3.9
5
  Tested up to: 4.9
6
- Stable tag: 1.7.9
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -283,6 +284,9 @@ To avoid being flagged as spam, you need to prove your email isn't forged. On a
283
 
284
  == Changelog ==
285
 
 
 
 
286
  = 1.7.9 - 2017-11-20
287
  * Fixed: misspled false
288
  * Fixed: feedback form
1
  === Post SMTP Mailer/Email Log ===
2
  Contributors: yehudah, jasonhendriks
3
+ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&business=yehuda@myinbox.in&item_name=Donation+for+PostSMTP
4
+ Tags: postman smtp, postman, smtp, email, mail, mailer, email log, oauth2, gmail, google apps, hotmail, yahoo, mandrill api, sendgrid api, elastic email, office365
5
  Requires at least: 3.9
6
  Tested up to: 4.9
7
+ Stable tag: 1.7.10
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
284
 
285
  == Changelog ==
286
 
287
+ = 1.7.10 - 2017-11-21 ==
288
+ * Fixed: bug while detecting transcript error
289
+
290
  = 1.7.9 - 2017-11-20
291
  * Fixed: misspled false
292
  * Fixed: feedback form