WordPress.org

Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #39610, comment 2


Ignore:
Timestamp:
01/17/2017 05:18:40 AM (3 years ago)
Author:
westonruter
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #39610, comment 2

    initial v1  
    1 The problem is that `\WP_Customize_Nav_Menus::insert_auto_draft_post()` was doing a `post_type_exists()` check. It's clear that for the purposes of this API method there needn't be a post type existence check, especially in the case of importing starter content. Note that `post_type_exists()` check is still present in `WP_Customize_Nav_Menus::ajax_insert_auto_draft_post()` and so the check was actually redundant.
     1The problem is that `\WP_Customize_Nav_Menus::insert_auto_draft_post()` was doing a `post_type_exists()` check and bailing. It's clear that for the purposes of this API method there needn't be a post type existence check, especially in the case of importing starter content. Note that `post_type_exists()` check is still present in `WP_Customize_Nav_Menus::ajax_insert_auto_draft_post()` and so the check was actually redundant.