Commit 2bf74459 authored by Erick Hitter's avatar Erick Hitter

Improve detection of data submitted in a POST request

Rather than check the request method, check for the presence of posted data upon which some script would have to act.
parent 682695f7
......@@ -311,7 +311,7 @@ try {
$load_wp = true;
// Relevant details on the current request
$is_post = (bool) 'POST' === $_SERVER['REQUEST_METHOD'];
$is_post = ( ! empty( $GLOBALS['HTTP_RAW_POST_DATA'] ) || ! empty( $_POST ) );
$logged_in = (bool) preg_match( "#(wordpress_(logged|sec)|comment_author)#", var_export( $_COOKIE, true ) );
if ( $redis_page_cache_config['debug'] ) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment