Make WordPress Core

Ticket #19077: 19077.2.patch

File 19077.2.patch, 614 bytes (added by SergeyBiryukov, 13 years ago)
  • wp-admin/includes/screen.php

     
    519519        function set_current_screen() {
    520520                global $current_screen, $taxnow, $typenow;
    521521                $current_screen = $this;
    522                 $taxnow = $this->taxonomy;
    523                 $typenow = $this->post_type;
     522                if ( !empty( $this->taxonomy ) )
     523                        $taxnow = $this->taxonomy;
     524                if ( !empty( $this->post_type ) )
     525                        $typenow = $this->post_type;
    524526                $current_screen = apply_filters( 'current_screen', $current_screen );
    525527        }
    526528