WordPress.org

Make WordPress Core

Ticket #11203: meta-boxes.php.diff

File meta-boxes.php.diff, 567 bytes (added by sirzooro, 5 years ago)
  • meta-boxes.php

    old new  
    184184<?php do_action('post_submitbox_start'); ?> 
    185185<div id="delete-action"> 
    186186<?php 
    187 if ( current_user_can("delete_${post_type}", $post->ID) ) { 
     187if ( ( 'edit' == $action ) && current_user_can("delete_${post_type}", $post->ID) ) { 
    188188        if ( !EMPTY_TRASH_DAYS ) { 
    189189                $delete_url = wp_nonce_url( add_query_arg( array('action' => 'delete', 'post' => $post->ID) ), "delete-${post_type}_{$post->ID}" ); 
    190190                $delete_text = __('Delete Permanently');