Fix notice in check_admin_referrer.
git-svn-id: http://svn.automattic.com/wordpress/trunk@9026 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
f419d59754
commit
42aaa50b6f
|
@ -772,7 +772,7 @@ if ( !function_exists('check_admin_referer') ) :
|
|||
function check_admin_referer($action = -1, $query_arg = '_wpnonce') {
|
||||
$adminurl = strtolower(admin_url());
|
||||
$referer = strtolower(wp_get_referer());
|
||||
$result = wp_verify_nonce($_REQUEST[$query_arg], $action);
|
||||
$result = isset($_REQUEST[$query_arg]) ? wp_verify_nonce($_REQUEST[$query_arg], $action) : false;
|
||||
if ( !$result && !(-1 == $action && strpos($referer, $adminurl) !== false) ) {
|
||||
wp_nonce_ays($action);
|
||||
die();
|
||||
|
|
Loading…
Reference in New Issue