Version Description
- Bugfix. Fixes filtering of debug email sent when using a development version of WordPress.
Download this release
Release Info
Developer | chipbennett |
Plugin | Update Control |
Version | 1.5 |
Comparing to | |
See all releases |
Code changes from version 1.4 to 1.5
- readme.txt +6 -3
- update-control.php +13 -10
readme.txt
CHANGED
@@ -2,8 +2,8 @@
|
|
2 |
Contributors: georgestephanis, chipbennett
|
3 |
Tags: automatic updates, updates
|
4 |
Requires at least: 3.7
|
5 |
-
Tested up to:
|
6 |
-
Stable tag: 1.
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
@@ -75,7 +75,7 @@ Update Result Emails
|
|
75 |
|
76 |
Debug Email
|
77 |
|
78 |
-
*
|
79 |
|
80 |
= Why don't automatic updates happen right away? =
|
81 |
|
@@ -85,6 +85,9 @@ Also, core now has two separate types of updates: manual updates and automatic u
|
|
85 |
|
86 |
== Changelog ==
|
87 |
|
|
|
|
|
|
|
88 |
= 1.4 =
|
89 |
* Bugfix. Fixes disabling all automatic updates not working.
|
90 |
|
2 |
Contributors: georgestephanis, chipbennett
|
3 |
Tags: automatic updates, updates
|
4 |
Requires at least: 3.7
|
5 |
+
Tested up to: 4.5
|
6 |
+
Stable tag: 1.5
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
75 |
|
76 |
Debug Email
|
77 |
|
78 |
+
* This email is sent by default when an update is performed on a site that is running a development version of WordPress. Enable this option to override the debug email, and prevent it from being sent.
|
79 |
|
80 |
= Why don't automatic updates happen right away? =
|
81 |
|
85 |
|
86 |
== Changelog ==
|
87 |
|
88 |
+
= 1.5 =
|
89 |
+
* Bugfix. Fixes filtering of debug email sent when using a development version of WordPress.
|
90 |
+
|
91 |
= 1.4 =
|
92 |
* Bugfix. Fixes disabling all automatic updates not working.
|
93 |
|
update-control.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
* Plugin URI: http://github.com/chipbennett/update-control/
|
5 |
* Description: Adds a manual toggle to the WordPress Admin Interface for managing auto-updates.
|
6 |
* Author: George Stephanis, Chip Bennett
|
7 |
-
* Version: 1.
|
8 |
* Author URI: http://chipbennett.net
|
9 |
*/
|
10 |
|
@@ -63,7 +63,7 @@ class Stephanis_Update_Control {
|
|
63 |
}
|
64 |
|
65 |
if ( $options['debugemail'] ) {
|
66 |
-
add_filter( 'automatic_updates_send_debug_email
|
67 |
}
|
68 |
|
69 |
}
|
@@ -212,13 +212,16 @@ class Stephanis_Update_Control {
|
|
212 |
'update-control'
|
213 |
);
|
214 |
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
|
219 |
-
|
220 |
-
|
221 |
-
|
|
|
|
|
|
|
222 |
|
223 |
register_setting( 'general', 'update_control_options', array( __CLASS__, 'sanitize_options' ) );
|
224 |
}
|
@@ -362,7 +365,7 @@ class Stephanis_Update_Control {
|
|
362 |
<?php
|
363 |
}
|
364 |
|
365 |
-
public static function sanitize_options( $options ) {
|
366 |
$options = (array) $options;
|
367 |
|
368 |
$options['active'] = ( in_array( $options['active'], array( 'yes', 'no' ) ) ? $options['active'] : 'yes' );
|
4 |
* Plugin URI: http://github.com/chipbennett/update-control/
|
5 |
* Description: Adds a manual toggle to the WordPress Admin Interface for managing auto-updates.
|
6 |
* Author: George Stephanis, Chip Bennett
|
7 |
+
* Version: 1.5
|
8 |
* Author URI: http://chipbennett.net
|
9 |
*/
|
10 |
|
63 |
}
|
64 |
|
65 |
if ( $options['debugemail'] ) {
|
66 |
+
add_filter( 'automatic_updates_send_debug_email', '__return_false', 1 );
|
67 |
}
|
68 |
|
69 |
}
|
212 |
'update-control'
|
213 |
);
|
214 |
|
215 |
+
global $wp_version;
|
216 |
+
if ( false !== strpos( $wp_version, '-' ) ) {
|
217 |
+
add_settings_field(
|
218 |
+
'update_control_email_debug',
|
219 |
+
sprintf( '<label for="update_control_email_debug">%1$s</label>', __( 'Disable Debug Emails for Development Versions?', 'update-control' ) ),
|
220 |
+
array( __CLASS__, 'update_control_email_debug_cb' ),
|
221 |
+
'general',
|
222 |
+
'update-control'
|
223 |
+
);
|
224 |
+
}
|
225 |
|
226 |
register_setting( 'general', 'update_control_options', array( __CLASS__, 'sanitize_options' ) );
|
227 |
}
|
365 |
<?php
|
366 |
}
|
367 |
|
368 |
+
public static function sanitize_options( $options ) {
|
369 |
$options = (array) $options;
|
370 |
|
371 |
$options['active'] = ( in_array( $options['active'], array( 'yes', 'no' ) ) ? $options['active'] : 'yes' );
|