WordPress.org

Make WordPress Core

Ticket #16061: 16061.diff

File 16061.diff, 2.4 KB (added by DH-Shredder, 3 years ago)

Initial patch -- "You do not have sufficient permissions to edit ..."

  • wp-admin/edit-comments.php

     
    152152                        $error_msg = __( 'Oops, no comment with this ID.' ); 
    153153                        break; 
    154154                case 2 : 
    155                         $error_msg = __( 'You are not allowed to edit comments on this post.' ); 
     155                        $error_msg = __( 'You do not have sufficient permissions to edit comments on this post.' ); 
    156156                        break; 
    157157        } 
    158158        if ( $error_msg ) 
  • wp-admin/includes/comment.php

     
    3434function edit_comment() { 
    3535 
    3636        if ( ! current_user_can( 'edit_comment', (int) $_POST['comment_ID'] ) ) 
    37                 wp_die ( __( 'You are not allowed to edit comments on this post.' ) ); 
     37                wp_die ( __( 'You do not have sufficient permissions to edit comments on this post.' ) ); 
    3838 
    3939        $_POST['comment_author'] = $_POST['newcomment_author']; 
    4040        $_POST['comment_author_email'] = $_POST['newcomment_author_email']; 
  • wp-admin/comment.php

     
    6161                comment_footer_die( __('Oops, no comment with this ID.') . sprintf(' <a href="%s">'.__('Go back').'</a>!', 'javascript:history.go(-1)') ); 
    6262 
    6363        if ( !current_user_can( 'edit_comment', $comment_id ) ) 
    64                 comment_footer_die( __('You are not allowed to edit this comment.') ); 
     64                comment_footer_die( __('You do not have sufficient permissions to edit this comment.') ); 
    6565 
    6666        if ( 'trash' == $comment->comment_approved ) 
    6767                comment_footer_die( __('This comment is in the Trash. Please move it out of the Trash if you want to edit it.') ); 
     
    214214        if ( !$comment = get_comment($comment_id) ) 
    215215                comment_footer_die( __('Oops, no comment with this ID.') . sprintf(' <a href="%s">'.__('Go back').'</a>!', 'edit-comments.php') ); 
    216216        if ( !current_user_can( 'edit_comment', $comment->comment_ID ) ) 
    217                 comment_footer_die( __('You are not allowed to edit comments on this post.') ); 
     217                comment_footer_die( __('You do not have sufficient permissions to edit comments on this post.') ); 
    218218 
    219219        if ( '' != wp_get_referer() && ! $noredir && false === strpos(wp_get_referer(), 'comment.php') ) 
    220220                $redir = wp_get_referer();