Asset CleanUp: Page Speed Booster - Version 1.2.8.7

Version Description

  • Bug Fix: When settings are reset to their default values via "Tools", make sure 'jQuery Migrate' and 'Comment Reply' are loading again if added in the bulk (site-wide) unload list (as by default they were not unloaded)
Download this release

Release Info

Developer gabelivan
Plugin Icon 128x128 Asset CleanUp: Page Speed Booster
Version 1.2.8.7
Comparing to
See all releases

Code changes from version 1.2.8.6 to 1.2.8.7

Files changed (3) hide show
  1. classes/Tools.php +14 -2
  2. readme.txt +4 -1
  3. wpacu.php +2 -2
classes/Tools.php CHANGED
@@ -66,13 +66,15 @@ class Tools
66
67
$this->resetChoice = $wpacuResetValue;
68
69
if ($wpacuResetValue === 'reset_everything') {
70
// `usermeta` and `termmeta` might have traces from the Pro version (if ever used)
71
foreach (array('postmeta', 'usermeta', 'termmeta') as $tableBaseName) {
72
$sqlQuery = <<<SQL
73
DELETE FROM `{$wpdb->prefix}{$tableBaseName}` WHERE meta_key LIKE '_wpassetcleanup_%'
74
SQL;
75
- $wpdb->query($sqlQuery);
76
}
77
78
$sqlQuery = <<<SQL
@@ -83,7 +85,17 @@ SQL;
83
$sqlQuery = <<<SQL
84
DELETE FROM `{$wpdb->prefix}options` WHERE option_name='wpassetcleanup_settings'
85
SQL;
86
- $wpdb->query($sqlQuery);
87
}
88
89
add_action('wpacu_admin_notices', array($this, 'resetDone'));
66
67
$this->resetChoice = $wpacuResetValue;
68
69
+ $resetStatus = false;
70
+
71
if ($wpacuResetValue === 'reset_everything') {
72
// `usermeta` and `termmeta` might have traces from the Pro version (if ever used)
73
foreach (array('postmeta', 'usermeta', 'termmeta') as $tableBaseName) {
74
$sqlQuery = <<<SQL
75
DELETE FROM `{$wpdb->prefix}{$tableBaseName}` WHERE meta_key LIKE '_wpassetcleanup_%'
76
SQL;
77
+ $resetStatus = $wpdb->query($sqlQuery);
78
}
79
80
$sqlQuery = <<<SQL
85
$sqlQuery = <<<SQL
86
DELETE FROM `{$wpdb->prefix}options` WHERE option_name='wpassetcleanup_settings'
87
SQL;
88
+ $resetStatus = $wpdb->query($sqlQuery);
89
+ }
90
+
91
+ // Also make 'jQuery Migrate' and 'Comment Reply' core files to load again
92
+ // As they were enabled (not unloaded) in the default settings
93
+ if ($resetStatus !== false) {
94
+ $wpacuUpdate = new Update();
95
+ $wpacuUpdate->removeEverywhereUnloads(
96
+ array(),
97
+ array('jquery-migrate' => 'remove', 'comment-reply' => 'remove')
98
+ );
99
}
100
101
add_action('wpacu_admin_notices', array($this, 'resetDone'));
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: pagespeed, page speed, dequeue, performance, gtmetrix
4
Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7GJZCW6RD8ECS
5
Requires at least: 4.0
6
Tested up to: 5.0.1
7
- Stable tag: 1.2.8.6
8
License: GPLv3
9
License URI: http://www.gnu.org/licenses/gpl.html
10
@@ -131,6 +131,9 @@ If that's the case, then it's advisable to consult with a developer (ideally the
131
4. Scripts (.JS) are selected for site-wide unload
132
133
== Changelog ==
134
= 1.2.8.6 =
135
* Better support for WordPress 5.0 when updating a post/page within the Dashboard
136
* On new plugin installations, "Hide WordPress Core Files From The Assets List?" is enabled by default
4
Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7GJZCW6RD8ECS
5
Requires at least: 4.0
6
Tested up to: 5.0.1
7
+ Stable tag: 1.2.8.7
8
License: GPLv3
9
License URI: http://www.gnu.org/licenses/gpl.html
10
131
4. Scripts (.JS) are selected for site-wide unload
132
133
== Changelog ==
134
+ = 1.2.8.7 =
135
+ * Bug Fix: When settings are reset to their default values via "Tools", make sure 'jQuery Migrate' and 'Comment Reply' are loading again if added in the bulk (site-wide) unload list (as by default they were not unloaded)
136
+
137
= 1.2.8.6 =
138
* Better support for WordPress 5.0 when updating a post/page within the Dashboard
139
* On new plugin installations, "Hide WordPress Core Files From The Assets List?" is enabled by default
wpacu.php CHANGED
@@ -2,13 +2,13 @@
2
/*
3
* Plugin Name: Asset CleanUp: Page Speed Booster
4
* Plugin URI: https://wordpress.org/plugins/wp-asset-clean-up/
5
- * Version: 1.2.8.6
6
* Description: Prevent Chosen Scripts & Styles from loading in Posts/Pages to reduce HTTP Requests and have the website load faster
7
* Author: Gabriel Livan
8
* Author URI: http://gabelivan.com/
9
*/
10
11
- define('WPACU_PLUGIN_VERSION', '1.2.8.6');
12
13
// Exit if accessed directly
14
if (! defined('ABSPATH')) {
2
/*
3
* Plugin Name: Asset CleanUp: Page Speed Booster
4
* Plugin URI: https://wordpress.org/plugins/wp-asset-clean-up/
5
+ * Version: 1.2.8.7
6
* Description: Prevent Chosen Scripts & Styles from loading in Posts/Pages to reduce HTTP Requests and have the website load faster
7
* Author: Gabriel Livan
8
* Author URI: http://gabelivan.com/
9
*/
10
11
+ define('WPACU_PLUGIN_VERSION', '1.2.8.7');
12
13
// Exit if accessed directly
14
if (! defined('ABSPATH')) {