Make WordPress Core


Ignore:
Timestamp:
02/08/2021 09:37:34 PM (4 years ago)
Author:
ocean90
Message:

Block Editor: Use a unique name for the nonce of the custom fields toggle form.

Avoids a browser warning for having two elements with a non-unique id #_wpnonce on the post edit screen.

See #23165.
Fixes #51483.
Props vandestouwe, Mista-Flo.

File:
1 edited

Legend:

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

    r49125 r50255  
    340340
    341341    case 'toggle-custom-fields':
    342         check_admin_referer( 'toggle-custom-fields' );
     342        check_admin_referer( 'toggle-custom-fields', 'toggle-custom-fields-nonce' );
    343343
    344344        $current_user_id = get_current_user_id();
Note: See TracChangeset for help on using the changeset viewer.