WP-Optimize - Version 3.0.4

Version Description

  • 20/Jul/2019 =

  • FIX: Fixed a regression in 3.0 with orphaned relationship data optimization

Download this release

Release Info

Developer DavidAnderson
Plugin Icon 128x128 WP-Optimize
Version 3.0.4
Comparing to
See all releases

Code changes from version 3.0.3 to 3.0.4

Files changed (3) hide show
  1. optimizations/orphandata.php +2 -2
  2. readme.txt +6 -2
  3. wp-optimize.php +2 -2
optimizations/orphandata.php CHANGED
@@ -28,7 +28,7 @@ class WP_Optimization_orphandata extends WP_Optimization {
28
  * Do optimization.
29
  */
30
  public function optimize() {
31
- $clean = "DELETE FROM `" . $this->wpdb->term_relationships . "` WHERE object_id NOT IN (SELECT id FROM `" . $this->wpdb->posts . "`);";
32
 
33
  $orphandata = $this->query($clean);
34
  $this->processed_count += $orphandata;
@@ -55,7 +55,7 @@ class WP_Optimization_orphandata extends WP_Optimization {
55
  * Get count of unoptimized items.
56
  */
57
  public function get_info() {
58
- $sql = "SELECT COUNT(*) FROM `" . $this->wpdb->term_relationships . "` WHERE object_id NOT IN (SELECT id FROM `" . $this->wpdb->posts . "`);";
59
  $orphandata = $this->wpdb->get_var($sql);
60
 
61
  $this->found_count += $orphandata;
28
  * Do optimization.
29
  */
30
  public function optimize() {
31
+ $clean = "DELETE FROM `" . $this->wpdb->term_relationships . "` WHERE term_taxonomy_id=1 AND object_id NOT IN (SELECT id FROM `" . $this->wpdb->posts . "`);";
32
 
33
  $orphandata = $this->query($clean);
34
  $this->processed_count += $orphandata;
55
  * Get count of unoptimized items.
56
  */
57
  public function get_info() {
58
+ $sql = "SELECT COUNT(*) FROM `" . $this->wpdb->term_relationships . "` WHERE term_taxonomy_id=1 AND object_id NOT IN (SELECT id FROM `" . $this->wpdb->posts . "`);";
59
  $orphandata = $this->wpdb->get_var($sql);
60
 
61
  $this->found_count += $orphandata;
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://david.dw-perspective.org.uk/donate
4
  Tags: cache, optimizing, database, image optimize, performance, clean, spam, speed, caching, smush, smushing
5
  Requires at least: 3.8
6
  Tested up to: 5.2
7
- Stable tag: 3.0.3
8
  License: GPLv2+
9
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -174,6 +174,10 @@ Please check your database for corrupted tables. That can happen, usually your w
174
 
175
  == Changelog ==
176
 
 
 
 
 
177
  = 3.0.3 - 20/Jul/2019 =
178
 
179
  * TWEAK: Prevent saving of page cache settings when the page cache was already off and another page cache plugin was active from over-writing the other plugin's advanced-cache.php
@@ -585,4 +589,4 @@ Please check your database for corrupted tables. That can happen, usually your w
585
  * Fix Interface
586
 
587
  == Upgrade Notice ==
588
- * 3.0.3: 3.0 introduces a new major feature: Page caching, as well as various small improvements, tweaks and fixes. A recommended update for all. 3.0.1/2/3 releases add small tweaks/fixes.
4
  Tags: cache, optimizing, database, image optimize, performance, clean, spam, speed, caching, smush, smushing
5
  Requires at least: 3.8
6
  Tested up to: 5.2
7
+ Stable tag: 3.0.4
8
  License: GPLv2+
9
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
10
 
174
 
175
  == Changelog ==
176
 
177
+ = 3.0.4 - 20/Jul/2019 =
178
+
179
+ * FIX: Fixed a regression in 3.0 with orphaned relationship data optimization
180
+
181
  = 3.0.3 - 20/Jul/2019 =
182
 
183
  * TWEAK: Prevent saving of page cache settings when the page cache was already off and another page cache plugin was active from over-writing the other plugin's advanced-cache.php
589
  * Fix Interface
590
 
591
  == Upgrade Notice ==
592
+ * 3.0.4: 3.0 introduces a new major feature: Page caching, as well as various small improvements, tweaks and fixes. A recommended update for all. 3.0.1-4 releases add small tweaks/fixes.
wp-optimize.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: WP-Optimize - Clean, Compress, Cache
4
  Plugin URI: https://getwpo.com
5
  Description: WP-Optimize makes your site fast and efficient. It cleans the database, compresses images and caches pages. Fast sites attract more traffic and users.
6
- Version: 3.0.3
7
  Author: David Anderson, Ruhani Rabin, Team Updraft
8
  Author URI: https://updraftplus.com
9
  Text Domain: wp-optimize
@@ -15,7 +15,7 @@ if (!defined('ABSPATH')) die('No direct access allowed');
15
 
16
  // Check to make sure if WP_Optimize is already call and returns.
17
  if (!class_exists('WP_Optimize')) :
18
- define('WPO_VERSION', '3.0.3');
19
  define('WPO_PLUGIN_URL', plugin_dir_url(__FILE__));
20
  define('WPO_PLUGIN_MAIN_PATH', plugin_dir_path(__FILE__));
21
  define('WPO_PREMIUM_NOTIFICATION', false);
3
  Plugin Name: WP-Optimize - Clean, Compress, Cache
4
  Plugin URI: https://getwpo.com
5
  Description: WP-Optimize makes your site fast and efficient. It cleans the database, compresses images and caches pages. Fast sites attract more traffic and users.
6
+ Version: 3.0.4
7
  Author: David Anderson, Ruhani Rabin, Team Updraft
8
  Author URI: https://updraftplus.com
9
  Text Domain: wp-optimize
15
 
16
  // Check to make sure if WP_Optimize is already call and returns.
17
  if (!class_exists('WP_Optimize')) :
18
+ define('WPO_VERSION', '3.0.4');
19
  define('WPO_PLUGIN_URL', plugin_dir_url(__FILE__));
20
  define('WPO_PLUGIN_MAIN_PATH', plugin_dir_path(__FILE__));
21
  define('WPO_PREMIUM_NOTIFICATION', false);