Make WordPress Core

Ticket #40178: 40178.diff

File 40178.diff, 913 bytes (added by bor0, 8 years ago)
  • wp-includes/nav-menu.php

     
    692692 * - type_label:       The singular label used to describe this type of menu item.
    693693 * - url:              The URL to which this menu item points.
    694694 * - xfn:              The XFN relationship expressed in the link of this menu item.
    695  * - _invalid:         Whether the menu item represents an object that no longer exists.
     695 * - _invalid:         Whether the menu item represents an object that no longer exists or is not published.
    696696 *
    697697 * @since 3.0.0
    698698 *
     
    717717                                        $menu_item->_invalid = true;
    718718                                }
    719719
    720                                 if ( 'trash' === get_post_status( $menu_item->object_id ) ) {
     720                                if ( 'publish' !== get_post_status( $menu_item->object_id ) ) {
    721721                                        $menu_item->_invalid = true;
    722722                                }
    723723