From 2f167faeb288361b1b04ec7dbcf1c2d70979646e Mon Sep 17 00:00:00 2001 From: Scott Taylor Date: Sat, 26 Sep 2015 04:51:26 +0000 Subject: [PATCH] Cron: In `spawn_cron()`, when using `ALTERNATE_WP_CRON`, return early for any non-`GET`, instead of naively checking `! empty( $_POST )`. Props johnbillion, markoheijnen. Fixes #27447. Built from https://develop.svn.wordpress.org/trunk@34576 git-svn-id: http://core.svn.wordpress.org/trunk@34540 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/cron.php | 2 +- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/cron.php b/wp-includes/cron.php index b6daeffc74..60492c5d04 100644 --- a/wp-includes/cron.php +++ b/wp-includes/cron.php @@ -269,7 +269,7 @@ function spawn_cron( $gmt_time = 0 ) { return; if ( defined( 'ALTERNATE_WP_CRON' ) && ALTERNATE_WP_CRON ) { - if ( ! empty( $_POST ) || defined( 'DOING_AJAX' ) || defined( 'XMLRPC_REQUEST' ) ) { + if ( 'GET' !== $_SERVER['REQUEST_METHOD'] || defined( 'DOING_AJAX' ) || defined( 'XMLRPC_REQUEST' ) ) { return; } diff --git a/wp-includes/version.php b/wp-includes/version.php index 6e5cd2c370..3c26e9d881 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.4-alpha-34575'; +$wp_version = '4.4-alpha-34576'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.