From f96fff3c9da59efe2491e0bb2cade14b71cb0f0d Mon Sep 17 00:00:00 2001 From: Scott Taylor Date: Sun, 28 Aug 2016 02:25:27 +0000 Subject: [PATCH] Admin: allow `WP_Screen` to be checked via autoload in `convert_to_screen()`. Props kraftbj. See #36335. Built from https://develop.svn.wordpress.org/trunk@38414 git-svn-id: http://core.svn.wordpress.org/trunk@38355 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/template.php | 2 +- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php index 6d3fb0d715..dce84fc43a 100644 --- a/wp-admin/includes/template.php +++ b/wp-admin/includes/template.php @@ -1989,7 +1989,7 @@ function _wp_admin_html_begin() { * @return WP_Screen Screen object. */ function convert_to_screen( $hook_name ) { - if ( ! class_exists( 'WP_Screen', false ) ) { + if ( ! class_exists( 'WP_Screen' ) ) { _doing_it_wrong( 'convert_to_screen(), add_meta_box()', __( "Likely direct inclusion of wp-admin/includes/template.php in order to use add_meta_box(). This is very wrong. Hook the add_meta_box() call into the add_meta_boxes action instead." ), '3.3.0' ); return (object) array( 'id' => '_invalid', 'base' => '_are_belong_to_us' ); } diff --git a/wp-includes/version.php b/wp-includes/version.php index df3109ddd6..8b5166a403 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.7-alpha-38413'; +$wp_version = '4.7-alpha-38414'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.