Make WordPress Core

Changeset 44615


Ignore:
Timestamp:
01/16/2019 05:40:04 AM (6 years ago)
Author:
pento
Message:

Admin: Use is_user_logged_in() instead of wp_validate_auth_cookie() in admin-post.php.

This matches the authentication check in admin-ajax.php, and allows the authentication method to be filtered.

Props jmdodd.
Fixes #45475.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/admin-post.php

    r44331 r44615  
    3232$action = empty( $_REQUEST['action'] ) ? '' : $_REQUEST['action'];
    3333
    34 if ( ! wp_validate_auth_cookie() ) {
     34if ( ! is_user_logged_in() ) {
    3535    if ( empty( $action ) ) {
    3636        /**
Note: See TracChangeset for help on using the changeset viewer.