Make WordPress Core

Changeset 43863


Ignore:
Timestamp:
11/04/2018 11:22:25 PM (6 years ago)
Author:
pento
Message:

Meta Boxes: Add curly brackets missed in [43861].

This was causing the custom meta box to be incorrectly added to post types that don't support it.

Props ocean90, epointal.
Fixes #45257,

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/5.0/src/wp-admin/includes/meta-boxes.php

    r43861 r43863  
    13611361        add_meta_box('trackbacksdiv', __('Send Trackbacks'), 'post_trackback_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => true ) );
    13621362
    1363     if ( post_type_supports($post_type, 'custom-fields') )
     1363    if ( post_type_supports($post_type, 'custom-fields') ) {
    13641364        $screen = get_current_screen();
    13651365        if ( ! $screen || ! $screen->is_block_editor() || (bool) get_user_meta( get_current_user_id(), 'enable_custom_fields', true ) ) {
    13661366            add_meta_box('postcustom', __('Custom Fields'), 'post_custom_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => false, '__block_editor_compatible_meta_box' => true ) );
    13671367        }
     1368    }
    13681369
    13691370    /**
Note: See TracChangeset for help on using the changeset viewer.