Make WordPress Core

Ticket #43743: 43743.2.diff

File 43743.2.diff, 1.1 KB (added by swissspidy, 5 years ago)
  • src/wp-admin/edit-tags.php

    diff --git src/wp-admin/edit-tags.php src/wp-admin/edit-tags.php
    index c71212b95c..998c06e3c3 100644
    endif; 
    354354
    355355</form>
    356356
     357<?php
     358$can_edit_terms = current_user_can( $tax->cap->edit_terms );
     359
     360if ( $can_edit_terms ) {
     361?>
    357362<div id="col-container" class="wp-clearfix">
    358363
    359364<div id="col-left">
    360365<div class="col-wrap">
    361366
    362367<?php
    363 
    364 if ( current_user_can( $tax->cap->edit_terms ) ) {
    365368        if ( 'category' == $taxonomy ) {
    366369                /**
    367370                 * Fires before the Add Category form.
    if ( current_user_can( $tax->cap->edit_terms ) ) { 
    559562        do_action( "{$taxonomy}_add_form", $taxonomy );
    560563        ?>
    561564</form></div>
    562 <?php } ?>
    563 
    564565</div>
    565566</div><!-- /col-left -->
    566567
    567568<div id="col-right">
    568569<div class="col-wrap">
     570<?php } ?>
    569571
    570572<?php $wp_list_table->views(); ?>
    571573
    endif; 
    612614 * @param string $taxonomy The taxonomy name.
    613615 */
    614616do_action( "after-{$taxonomy}-table", $taxonomy );
    615 ?>
    616617
     618if ( $can_edit_terms ) {
     619?>
    617620</div>
    618621</div><!-- /col-right -->
    619622
    620623</div><!-- /col-container -->
     624<?php } ?>
     625
    621626</div><!-- /wrap -->
    622627
    623628<?php if ( ! wp_is_mobile() ) : ?>