Changeset 29714
- Timestamp:
- 09/07/2014 08:31:57 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/admin-bar.php
r29695 r29714 531 531 && ( $post_type_object = get_post_type_object( $current_object->post_type ) ) 532 532 && current_user_can( 'edit_post', $current_object->ID ) 533 && $post_type_object->show_ui && $post_type_object->show_in_admin_bar ) 533 && $post_type_object->show_ui && $post_type_object->show_in_admin_bar 534 && $edit_post_link = get_edit_post_link( $current_object->ID ) ) 534 535 { 535 536 $wp_admin_bar->add_menu( array( 536 537 'id' => 'edit', 537 538 'title' => $post_type_object->labels->edit_item, 538 'href' => get_edit_post_link( $current_object->ID )539 'href' => 539 540 ) ); 540 541 } elseif ( ! empty( $current_object->taxonomy ) 541 542 && ( $tax = get_taxonomy( $current_object->taxonomy ) ) 542 543 && current_user_can( $tax->cap->edit_terms ) 543 && $tax->show_ui ) 544 && $tax->show_ui 545 && $edit_term_link = get_edit_term_link( $current_object->term_id, $current_object->taxonomy ) ) 544 546 { 545 547 $wp_admin_bar->add_menu( array( 546 548 'id' => 'edit', 547 549 'title' => $tax->labels->edit_item, 548 'href' => get_edit_term_link( $current_object->term_id, $current_object->taxonomy )550 'href' => 549 551 ) ); 550 552 }
Note: See TracChangeset
for help on using the changeset viewer.