Ticket #44965: 44965.patch
File 44965.patch, 1004 bytes (added by , 5 years ago) |
---|
-
src/wp-includes/class-wp.php
257 257 258 258 // If we're processing a 404 request, clear the error var since we found something. 259 259 if ( '404' == $error ) { 260 unset( $error , $_GET['error']);260 unset( $error ); 261 261 } 262 262 } 263 263 264 264 // If req_uri is empty or if it is a request for ourself, unset error. 265 265 if ( empty( $requested_path ) || $requested_file == $self || strpos( $_SERVER['PHP_SELF'], 'wp-admin/' ) !== false ) { 266 unset( $error , $_GET['error']);266 unset( $error ); 267 267 268 268 if ( isset( $perma_query_vars ) && strpos( $_SERVER['PHP_SELF'], 'wp-admin/' ) !== false ) { 269 269 unset( $perma_query_vars ); … … 364 364 365 365 if ( isset( $error ) ) { 366 366 $this->query_vars['error'] = $error; 367 } elseif ( ! empty( $rewrite ) ) { 368 unset( $this->query_vars['error'] ); 367 369 } 368 370 369 371 /**