diff --git a/wp-admin/includes/nav-menu.php b/wp-admin/includes/nav-menu.php index c8b2ede188..0b4b0b0b3e 100644 --- a/wp-admin/includes/nav-menu.php +++ b/wp-admin/includes/nav-menu.php @@ -23,9 +23,6 @@ function wp_nav_menu_post_type_metaboxes() { continue; $id = $post_type->name; - // delete_transient( "nav_menu_items_{$post_type->name}" ); - // delete_transient( "nav_menu_sub_items_{$post_type->name}" ); - add_meta_box( "add-{$id}", sprintf( __('Add an Existing %s'), $post_type->singular_label ), 'wp_nav_menu_item_post_type_metabox', 'menus', 'side', 'default', $post_type ); } } @@ -47,9 +44,6 @@ function wp_nav_menu_taxonomy_metaboxes() { continue; $id = $tax->name; - // delete_transient( "nav_menu_items_{$tax->name}" ); - // delete_transient( "nav_menu_sub_items_{$tax->name}" ); - add_meta_box( "add-{$id}", sprintf( __('Add an Existing %s'), $tax->singular_label ), 'wp_nav_menu_item_taxonomy_metabox', 'menus', 'side', 'default', $tax ); } } @@ -106,12 +100,8 @@ function wp_nav_menu_create_metabox() { ?> function wp_nav_menu_item_link_metabox() { $args = array( 'post_status' => 'any', 'post_type' => 'nav_menu_item', 'meta_value' => 'custom' ); - // Cache the query for a day. @todo: Make sure to flush transient when links are updated. - $query = get_transient( 'menu_item_query_custom_links' ); - if ( false == $query ) { - $query = new WP_Query( $args ); - set_transient( 'menu_item_query_custom_links', $query, 86400 ); - } + // @todo transient caching of these results with proper invalidation on updating links + $query = new WP_Query( $args ); ?>