From 97ea98f145ecafc19d8e996a4149b9c3748e9f57 Mon Sep 17 00:00:00 2001 From: Scott Taylor Date: Wed, 31 Aug 2016 06:28:19 +0000 Subject: [PATCH] Press This: don't check for already-hoisted global in `press-this.php`. See #37699. git-svn-id: https://develop.svn.wordpress.org/trunk@38466 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/press-this.php | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/wp-admin/press-this.php b/src/wp-admin/press-this.php index 2fb81ed2e4..1fb7fe2779 100644 --- a/src/wp-admin/press-this.php +++ b/src/wp-admin/press-this.php @@ -19,11 +19,5 @@ if ( ! current_user_can( 'edit_posts' ) || ! current_user_can( get_post_type_obj ); } -/** - * @global WP_Press_This $wp_press_this - */ -if ( empty( $GLOBALS['wp_press_this'] ) ) { - $GLOBALS['wp_press_this'] = new WP_Press_This(); -} - -$GLOBALS['wp_press_this']->html(); +$wp_press_this = new WP_Press_This(); +$wp_press_this->html();