Version Description
- Fixing a bug that resets settings to defaults during the upgrade for users in AddThis mode
- Reverting to pre-5.0.9 settings of plugin for upgrades from 5.0.9, 5.0.10 and 5.0.11
Download this release
Release Info
Developer | jgrodel |
Plugin | WordPress Share Buttons Plugin – AddThis |
Version | 5.0.12 |
Comparing to | |
See all releases |
Code changes from version 5.0.11 to 5.0.12
- AddThisWordPressConnector.php +19 -7
- AddThisWordPressSharingButtonsPlugin.php +1 -1
- addthis_social_widget.php +1 -1
- readme.txt +9 -1
AddThisWordPressConnector.php
CHANGED
@@ -357,20 +357,32 @@ if (!class_exists('AddThisWordPressConnector')) {
|
|
357 |
$migrationVariable = $this->migrationStatusVariable();
|
358 |
|
359 |
$oldConfigs = $this->recurseForOldConfigs($this->plugin->getOldConfigVariableName());
|
360 |
-
|
361 |
-
|
|
|
362 |
) {
|
363 |
-
if (is_array($this->configs)) {
|
364 |
$this->configs = array_merge($oldConfigs, $this->configs);
|
365 |
-
} else {
|
366 |
$this->configs = $oldConfigs;
|
367 |
}
|
368 |
|
369 |
-
$
|
370 |
-
update_option($this->migratedConfigSettingsName, $
|
|
|
371 |
|
372 |
-
|
|
|
|
|
|
|
|
|
373 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
374 |
}
|
375 |
|
376 |
public function upgradeConfigs() {
|
357 |
$migrationVariable = $this->migrationStatusVariable();
|
358 |
|
359 |
$oldConfigs = $this->recurseForOldConfigs($this->plugin->getOldConfigVariableName());
|
360 |
+
|
361 |
+
if ( !isset($oldConfigs[$migrationVariable])
|
362 |
+
|| $oldConfigs[$migrationVariable] !== $this->plugin->getConfigVariableName()
|
363 |
) {
|
364 |
+
if (is_array($this->configs) && is_array($oldConfigs)) {
|
365 |
$this->configs = array_merge($oldConfigs, $this->configs);
|
366 |
+
} else if (is_array($oldConfigs)) {
|
367 |
$this->configs = $oldConfigs;
|
368 |
}
|
369 |
|
370 |
+
$updatedOldConfigs[$migrationVariable] = $this->plugin->getConfigVariableName();
|
371 |
+
update_option($this->migratedConfigSettingsName, $updatedOldConfigs);
|
372 |
+
}
|
373 |
|
374 |
+
$badUpgradeVersions = array('5.0.9', '5.0.10', '5.0.11');
|
375 |
+
if (!empty($this->configs['addthis_plugin_version'])) {
|
376 |
+
$oldVersion = $this->configs['addthis_plugin_version'];
|
377 |
+
} else {
|
378 |
+
$oldVersion = 'unknown';
|
379 |
}
|
380 |
+
|
381 |
+
if (in_array($oldVersion, $badUpgradeVersions)) {
|
382 |
+
$this->configs = $oldConfigs;
|
383 |
+
}
|
384 |
+
|
385 |
+
return $this->configs;
|
386 |
}
|
387 |
|
388 |
public function upgradeConfigs() {
|
AddThisWordPressSharingButtonsPlugin.php
CHANGED
@@ -25,7 +25,7 @@ if (!class_exists('AddThisWordPressSharingButtonsPlugin')) {
|
|
25 |
Class AddThisWordPressSharingButtonsPlugin {
|
26 |
// implements AddThisWordPressPluginInterface {
|
27 |
|
28 |
-
static $version = '5.0.
|
29 |
static $settingsPageId = 'addthis_social_widget';
|
30 |
static $name = "AddThis Sharing Buttons";
|
31 |
static $productPrefix = 'wpp';
|
25 |
Class AddThisWordPressSharingButtonsPlugin {
|
26 |
// implements AddThisWordPressPluginInterface {
|
27 |
|
28 |
+
static $version = '5.0.12';
|
29 |
static $settingsPageId = 'addthis_social_widget';
|
30 |
static $name = "AddThis Sharing Buttons";
|
31 |
static $productPrefix = 'wpp';
|
addthis_social_widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: AddThis Sharing Buttons
|
4 |
* Plugin URI: http://www.addthis.com
|
5 |
* Description: Use the AddThis suite of website tools which includes sharing, following, recommended content, and conversion tools to help you make your website smarter. With AddThis, you can see how your users are engaging with your content, provide a personalized experience for each user and encourage them to share, subscribe or follow.
|
6 |
-
* Version: 5.0.
|
7 |
* Author: The AddThis Team
|
8 |
* Author URI: http://www.addthis.com/
|
9 |
* License: GPL2
|
3 |
* Plugin Name: AddThis Sharing Buttons
|
4 |
* Plugin URI: http://www.addthis.com
|
5 |
* Description: Use the AddThis suite of website tools which includes sharing, following, recommended content, and conversion tools to help you make your website smarter. With AddThis, you can see how your users are engaging with your content, provide a personalized experience for each user and encourage them to share, subscribe or follow.
|
6 |
+
* Version: 5.0.12
|
7 |
* Author: The AddThis Team
|
8 |
* Author URI: http://www.addthis.com/
|
9 |
* License: GPL2
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: abramsm, srijith.v, vipinss, dnrahamim, jgrodel, bradaddthiscom, m
|
|
3 |
Tags: AddThis, addtoany, bookmark, bookmarking, email, e-mail, sharing buttons, share, share this, facebook, google+, pinterest, instagram, linkedin, whatsapp, social tools, website tools, twitter, content marketing, recommended content, conversion tool, subscription button, conversion tools, email tools, ecommerce tools, social marketing, personalization tools
|
4 |
Requires at least: 3.0
|
5 |
Tested up to: 4.2.2
|
6 |
-
Stable tag: 5.0.
|
7 |
|
8 |
AddThis provides the best sharing tools to help you make your website smarter.
|
9 |
|
@@ -76,6 +76,10 @@ PHP 5+ is preferred; PHP 4 is supported.
|
|
76 |
|
77 |
== Changelog ==
|
78 |
|
|
|
|
|
|
|
|
|
79 |
= 5.0.11 =
|
80 |
* Fixing overwrite of $addThisConfig global to resolve more PHP errors where a function is called from a non-object
|
81 |
|
@@ -361,6 +365,10 @@ Fixed nondeterministic bug with the_title(), causing the title to occasionally a
|
|
361 |
|
362 |
== Upgrade Notice ==
|
363 |
|
|
|
|
|
|
|
|
|
364 |
= 5.0.11 =
|
365 |
* Fixing overwrite of $addThisConfig global to resolve more PHP errors where a function is called from a non-object
|
366 |
|
3 |
Tags: AddThis, addtoany, bookmark, bookmarking, email, e-mail, sharing buttons, share, share this, facebook, google+, pinterest, instagram, linkedin, whatsapp, social tools, website tools, twitter, content marketing, recommended content, conversion tool, subscription button, conversion tools, email tools, ecommerce tools, social marketing, personalization tools
|
4 |
Requires at least: 3.0
|
5 |
Tested up to: 4.2.2
|
6 |
+
Stable tag: 5.0.12
|
7 |
|
8 |
AddThis provides the best sharing tools to help you make your website smarter.
|
9 |
|
76 |
|
77 |
== Changelog ==
|
78 |
|
79 |
+
= 5.0.12 =
|
80 |
+
* Fixing a bug that resets settings to defaults during the upgrade for users in AddThis mode
|
81 |
+
* Reverting to pre-5.0.9 settings of plugin for upgrades from 5.0.9, 5.0.10 and 5.0.11
|
82 |
+
|
83 |
= 5.0.11 =
|
84 |
* Fixing overwrite of $addThisConfig global to resolve more PHP errors where a function is called from a non-object
|
85 |
|
365 |
|
366 |
== Upgrade Notice ==
|
367 |
|
368 |
+
= 5.0.12 =
|
369 |
+
* Fixing a bug that resets settings to defaults during the upgrade for users in AddThis mode
|
370 |
+
* Reverting to pre-5.0.9 settings of plugin for upgrades from 5.0.9, 5.0.10 and 5.0.11
|
371 |
+
|
372 |
= 5.0.11 =
|
373 |
* Fixing overwrite of $addThisConfig global to resolve more PHP errors where a function is called from a non-object
|
374 |
|