Email Subscribers & Newsletters - Version 4.5.0.1

Version Description

Download this release

Release Info

Developer Icegram
Plugin Icon 128x128 Email Subscribers & Newsletters
Version 4.5.0.1
Comparing to
See all releases

Code changes from version 4.5.0 to 4.5.0.1

email-subscribers.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Email Subscribers & Newsletters
4
  * Plugin URI: https://www.icegram.com/
5
  * Description: Add subscription forms on website, send HTML newsletters & automatically notify subscribers about new blog posts once it is published.
6
- * Version: 4.5.0
7
  * Author: Icegram
8
  * Author URI: https://www.icegram.com/
9
  * Requires at least: 3.9
@@ -156,7 +156,7 @@ if ( $is_premium ) {
156
  /* ***************************** Initial Compatibility Work (End) ******************* */
157
 
158
  if ( ! defined( 'ES_PLUGIN_VERSION' ) ) {
159
- define( 'ES_PLUGIN_VERSION', '4.5.0' );
160
  }
161
 
162
  // Plugin Folder Path.
3
  * Plugin Name: Email Subscribers & Newsletters
4
  * Plugin URI: https://www.icegram.com/
5
  * Description: Add subscription forms on website, send HTML newsletters & automatically notify subscribers about new blog posts once it is published.
6
+ * Version: 4.5.0.1
7
  * Author: Icegram
8
  * Author URI: https://www.icegram.com/
9
  * Requires at least: 3.9
156
  /* ***************************** Initial Compatibility Work (End) ******************* */
157
 
158
  if ( ! defined( 'ES_PLUGIN_VERSION' ) ) {
159
+ define( 'ES_PLUGIN_VERSION', '4.5.0.1' );
160
  }
161
 
162
  // Plugin Folder Path.
lite/includes/classes/class-es-mailer.php CHANGED
@@ -725,8 +725,6 @@ if ( ! class_exists( 'ES_Mailer' ) ) {
725
  // Can Track Email Open? Add pixel.
726
  $email_tracking_image = $this->get_tracking_pixel();
727
 
728
- $email_tracking_user_device = apply_filters( 'ig_es_tracking_user_device', '' );
729
-
730
  $message->body = $message->body . $unsubscribe_message . $email_tracking_image;
731
 
732
  if ( $nl2br ) {
725
  // Can Track Email Open? Add pixel.
726
  $email_tracking_image = $this->get_tracking_pixel();
727
 
 
 
728
  $message->body = $message->body . $unsubscribe_message . $email_tracking_image;
729
 
730
  if ( $nl2br ) {
lite/includes/classes/class-es-queue.php CHANGED
@@ -669,6 +669,13 @@ if ( ! class_exists( 'ES_Queue' ) ) {
669
 
670
  if( 'newsletter' === $campaign_type ) {
671
  ES()->campaigns_db->update_status( $campaign_id, IG_ES_CAMPAIGN_STATUS_FINISHED );
 
 
 
 
 
 
 
672
  }
673
 
674
  // Send Cron Email to admins
669
 
670
  if( 'newsletter' === $campaign_type ) {
671
  ES()->campaigns_db->update_status( $campaign_id, IG_ES_CAMPAIGN_STATUS_FINISHED );
672
+ } else if( 'post_digest' === $campaign_type ) {
673
+ $campaign_meta = ES()->campaigns_db->get_campaign_meta_by_id( $campaign_id );
674
+ if( ! empty( $campaign_meta['post_ids'] ) ) {
675
+ // Empty the post ids since they have already been sent in this campaign notification.
676
+ $campaign_meta['post_ids'] = array();
677
+ ES()->campaigns_db->update_campaign_meta( $campaign_id, $campaign_meta );
678
+ }
679
  }
680
 
681
  // Send Cron Email to admins
lite/includes/db/class-es-db-campaigns.php CHANGED
@@ -460,7 +460,7 @@ class ES_DB_Campaigns extends ES_DB {
460
  *
461
  * @return array|object|null
462
  */
463
- public function get_campaign_by_id( $id = 0, $status = self::STATUS_ACTIVE ) {
464
  global $wpdb;
465
 
466
  if ( empty( $id ) ) {
@@ -470,7 +470,7 @@ class ES_DB_Campaigns extends ES_DB {
470
  $where = $wpdb->prepare( "id = %d", $id );
471
 
472
  if( -1 !== $status ) {
473
- $where = $wpdb->prepare( " AND status = %d", self::STATUS_ACTIVE );
474
  }
475
 
476
  $campaigns = $this->get_by_conditions( $where );
@@ -559,6 +559,7 @@ class ES_DB_Campaigns extends ES_DB {
559
 
560
  $update = $this->save_campaign( $campaign, $campaign_id );
561
 
 
562
  }
563
  }
564
  }
460
  *
461
  * @return array|object|null
462
  */
463
+ public function get_campaign_by_id( $id = 0, $status = 1 ) {
464
  global $wpdb;
465
 
466
  if ( empty( $id ) ) {
470
  $where = $wpdb->prepare( "id = %d", $id );
471
 
472
  if( -1 !== $status ) {
473
+ $where .= $wpdb->prepare( " AND status = %d", $status );
474
  }
475
 
476
  $campaigns = $this->get_by_conditions( $where );
559
 
560
  $update = $this->save_campaign( $campaign, $campaign_id );
561
 
562
+
563
  }
564
  }
565
  }
readme.txt CHANGED
@@ -6,7 +6,7 @@ Tags: email marketing, subscription, autoresponder, post notification, welcome e
6
  Requires at least: 3.9
7
  Tested up to: 5.4.2
8
  Requires PHP: 5.6
9
- Stable tag: 4.5.0
10
  License: GPLv3
11
  License URI: http://www.gnu.org/licenses
12
 
@@ -302,6 +302,11 @@ Refer [here](https://www.icegram.com/documentation/es-faq/).
302
 
303
  == Changelog ==
304
 
 
 
 
 
 
305
  **4.5.0 (07.07.2020)**
306
 
307
  * New: Advance Campaign Reports [PRO]
6
  Requires at least: 3.9
7
  Tested up to: 5.4.2
8
  Requires PHP: 5.6
9
+ Stable tag: 4.5.0.1
10
  License: GPLv3
11
  License URI: http://www.gnu.org/licenses
12
 
302
 
303
  == Changelog ==
304
 
305
+ **4.5.0.1 (09.07.2020)**
306
+
307
+ * Fix: Duplicate campaign creation
308
+ * Fix: Post Digest Keywords issue [PRO]
309
+
310
  **4.5.0 (07.07.2020)**
311
 
312
  * New: Advance Campaign Reports [PRO]