WordPress Social Tools, Related Posts, Monetization – Shareaholic - Version 8.4.4

Version Description

  • Another critical bugfix for users of the SG Optimizer plugin (SiteGround hosting). This update will seamlessly allow you to re-activate Shareaholic.
Download this release

Release Info

Developer shareaholic
Plugin Icon 128x128 WordPress Social Tools, Related Posts, Monetization – Shareaholic
Version 8.4.4
Comparing to
See all releases

Code changes from version 8.4.3 to 8.4.4

Files changed (4) hide show
  1. cron.php +3 -3
  2. readme.txt +6 -1
  3. shareaholic.php +8 -10
  4. utilities.php +9 -3
cron.php CHANGED
@@ -66,9 +66,9 @@ class ShareaholicCron {
66
  ShareaholicUtilities::log('Transient Query Error!!!');
67
  }
68
  }
69
-
 
 
70
  ShareaholicUtilities::log('End of Shareaholic transient cleanup');
71
  }
72
-
73
-
74
  }
66
  ShareaholicUtilities::log('Transient Query Error!!!');
67
  }
68
  }
69
+ // Cleanup leftover mutex
70
+ ShareaholicUtilities::delete_mutex();
71
+
72
  ShareaholicUtilities::log('End of Shareaholic transient cleanup');
73
  }
 
 
74
  }
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: shareaholic
3
  Tags: share buttons, related content, cookie compliance, eu cookie law, shareaholic, shareholic, sexybookmarks, recommendations, cookie consent, email button, social sharing, social bookmarking, share image, image sharing, follow buttons, floated share buttons, floating share buttons, analytics, social media, social plugin, facebook, twitter, google plus, google bookmarks, gmail, linkedin, pinterest, reddit, tumblr, evernote, digg, delicious, stumbleupon, printfriendly, fancy, amazon, xing, vk, yahoo, mister wong, viadeo, odnoklassniki box.net, diigo, yammer, ycombinator, hotmail, instapaper, mixi, arto, whatsapp, hootsuite, inbound.org, plurk, aim, buffer, meneame, pinboard.in, stumpedia, bitly, blogger, yummly, izeby, kaboodle, weibo, instagram, tinyurl, typepad, weheartit, flipboard, pocket, wanelo, fark, wykop, symphony, kindle, houzz, youtube, sms, onenote, google classroom, disqus, spotify, zillow, feedly, kik, line, livejournal, baidu
4
  Requires at least: 3.0
5
  Tested up to: 4.8
6
- Stable tag: 8.4.3
7
 
8
  World's leading all-in-one Content Amplification Platform that helps grow your site traffic, engagement, conversions & monetization for FREE.
9
 
@@ -195,6 +195,8 @@ Please see here: [Shareaholic Helpdesk](http://support.shareaholic.com/hc/en-us)
195
  Please see here: [Usage & Installation Instructions](http://support.shareaholic.com/hc/en-us/categories/200101476-WordPress-Plugin)
196
 
197
  == Changelog ==
 
 
198
 
199
  = 8.4.3 (2017-09-20) =
200
  * Critical bugfix for users of SG Optimizer plugin
@@ -657,6 +659,9 @@ Please see here: [Usage & Installation Instructions](http://support.shareaholic.
657
  * Show Related Posts data status
658
 
659
  == Upgrade Notice ==
 
 
 
660
  = 8.4.3 =
661
  Critical bugfix for users of SG Optimizer plugin
662
 
3
  Tags: share buttons, related content, cookie compliance, eu cookie law, shareaholic, shareholic, sexybookmarks, recommendations, cookie consent, email button, social sharing, social bookmarking, share image, image sharing, follow buttons, floated share buttons, floating share buttons, analytics, social media, social plugin, facebook, twitter, google plus, google bookmarks, gmail, linkedin, pinterest, reddit, tumblr, evernote, digg, delicious, stumbleupon, printfriendly, fancy, amazon, xing, vk, yahoo, mister wong, viadeo, odnoklassniki box.net, diigo, yammer, ycombinator, hotmail, instapaper, mixi, arto, whatsapp, hootsuite, inbound.org, plurk, aim, buffer, meneame, pinboard.in, stumpedia, bitly, blogger, yummly, izeby, kaboodle, weibo, instagram, tinyurl, typepad, weheartit, flipboard, pocket, wanelo, fark, wykop, symphony, kindle, houzz, youtube, sms, onenote, google classroom, disqus, spotify, zillow, feedly, kik, line, livejournal, baidu
4
  Requires at least: 3.0
5
  Tested up to: 4.8
6
+ Stable tag: 8.4.4
7
 
8
  World's leading all-in-one Content Amplification Platform that helps grow your site traffic, engagement, conversions & monetization for FREE.
9
 
195
  Please see here: [Usage & Installation Instructions](http://support.shareaholic.com/hc/en-us/categories/200101476-WordPress-Plugin)
196
 
197
  == Changelog ==
198
+ = 8.4.4 (2017-09-21) =
199
+ * Another critical bugfix for users of the SG Optimizer plugin (SiteGround hosting). This update will seamlessly allow you to re-activate Shareaholic.
200
 
201
  = 8.4.3 (2017-09-20) =
202
  * Critical bugfix for users of SG Optimizer plugin
659
  * Show Related Posts data status
660
 
661
  == Upgrade Notice ==
662
+ = 8.4.4 =
663
+ * Another critical bugfix for users of the SG Optimizer plugin (SiteGround hosting). This update will seamlessly allow you to re-activate Shareaholic.
664
+
665
  = 8.4.3 =
666
  Critical bugfix for users of SG Optimizer plugin
667
 
shareaholic.php CHANGED
@@ -3,14 +3,14 @@
3
  * The main file!
4
  *
5
  * @package shareaholic
6
- * @version 8.4.3
7
  */
8
 
9
  /*
10
  Plugin Name: Shareaholic | share buttons, analytics, related content
11
  Plugin URI: https://shareaholic.com/publishers/
12
  Description: The world's leading all-in-one Content Amplification Platform that helps grow your website traffic, engagement, conversions & monetization. See <a href="admin.php?page=shareaholic-settings">configuration panel</a> for more settings.
13
- Version: 8.4.3
14
  Author: Shareaholic
15
  Author URI: https://shareaholic.com
16
  Text Domain: shareaholic
@@ -63,7 +63,7 @@ if (!class_exists('Shareaholic')) {
63
  const CM_API_URL = 'https://cm-web.shareaholic.com'; // uses static IPs for firewall whitelisting
64
  const REC_API_URL = 'http://recommendations.shareaholic.com';
65
 
66
- const VERSION = '8.4.3';
67
 
68
  /**
69
  * Starts off as false so that ::get_instance() returns
@@ -224,6 +224,9 @@ if (!class_exists('Shareaholic')) {
224
  * This function fires after the plugin has been activated.
225
  */
226
  public function after_activation() {
 
 
 
227
  $this->terms_of_service();
228
  ShareaholicUtilities::log_event("Activate");
229
 
@@ -241,9 +244,6 @@ if (!class_exists('Shareaholic')) {
241
 
242
  // Activate the Shareaholic Cron Job for new users
243
  ShareaholicCron::activate();
244
-
245
- // Clear site cache
246
- ShareaholicUtilities::clear_cache();
247
  }
248
 
249
  /**
@@ -253,8 +253,7 @@ if (!class_exists('Shareaholic')) {
253
  ShareaholicUtilities::log_event("Deactivate");
254
  ShareaholicUtilities::clear_cache();
255
  ShareaholicCron::deactivate();
256
- delete_option('shareaholic_get_or_create_api_key');
257
- delete_option('shareaholic_perform_update');
258
  }
259
 
260
  /**
@@ -264,8 +263,7 @@ if (!class_exists('Shareaholic')) {
264
  ShareaholicUtilities::log_event("Uninstall");
265
  ShareaholicUtilities::delete_api_key();
266
  delete_option('shareaholic_settings');
267
- delete_option('shareaholic_get_or_create_api_key');
268
- delete_option('shareaholic_perform_update');
269
  }
270
  }
271
 
3
  * The main file!
4
  *
5
  * @package shareaholic
6
+ * @version 8.4.4
7
  */
8
 
9
  /*
10
  Plugin Name: Shareaholic | share buttons, analytics, related content
11
  Plugin URI: https://shareaholic.com/publishers/
12
  Description: The world's leading all-in-one Content Amplification Platform that helps grow your website traffic, engagement, conversions & monetization. See <a href="admin.php?page=shareaholic-settings">configuration panel</a> for more settings.
13
+ Version: 8.4.4
14
  Author: Shareaholic
15
  Author URI: https://shareaholic.com
16
  Text Domain: shareaholic
63
  const CM_API_URL = 'https://cm-web.shareaholic.com'; // uses static IPs for firewall whitelisting
64
  const REC_API_URL = 'http://recommendations.shareaholic.com';
65
 
66
+ const VERSION = '8.4.4';
67
 
68
  /**
69
  * Starts off as false so that ::get_instance() returns
224
  * This function fires after the plugin has been activated.
225
  */
226
  public function after_activation() {
227
+ // Cleanup leftover mutex
228
+ ShareaholicUtilities::delete_mutex();
229
+
230
  $this->terms_of_service();
231
  ShareaholicUtilities::log_event("Activate");
232
 
244
 
245
  // Activate the Shareaholic Cron Job for new users
246
  ShareaholicCron::activate();
 
 
 
247
  }
248
 
249
  /**
253
  ShareaholicUtilities::log_event("Deactivate");
254
  ShareaholicUtilities::clear_cache();
255
  ShareaholicCron::deactivate();
256
+ ShareaholicUtilities::delete_mutex();
 
257
  }
258
 
259
  /**
263
  ShareaholicUtilities::log_event("Uninstall");
264
  ShareaholicUtilities::delete_api_key();
265
  delete_option('shareaholic_settings');
266
+ ShareaholicUtilities::delete_mutex();
 
267
  }
268
  }
269
 
utilities.php CHANGED
@@ -362,9 +362,6 @@ class ShareaholicUtilities {
362
  // add other things that need to run on version change here
363
 
364
  self::unlock('perform_update');
365
- } else {
366
- usleep(100000);
367
- self::perform_update();
368
  }
369
  }
370
 
@@ -610,6 +607,15 @@ class ShareaholicUtilities {
610
  public static function unlock($name) {
611
  delete_option('shareaholic_' . $name);
612
  }
 
 
 
 
 
 
 
 
 
613
 
614
  /**
615
  * Checks whether a plugin is active
362
  // add other things that need to run on version change here
363
 
364
  self::unlock('perform_update');
 
 
 
365
  }
366
  }
367
 
607
  public static function unlock($name) {
608
  delete_option('shareaholic_' . $name);
609
  }
610
+
611
+ /**
612
+ * Clears all mutex
613
+ *
614
+ */
615
+ public static function delete_mutex() {
616
+ delete_option('shareaholic_get_or_create_api_key');
617
+ delete_option('shareaholic_perform_update');
618
+ }
619
 
620
  /**
621
  * Checks whether a plugin is active