Make WordPress Core


Ignore:
Timestamp:
11/15/2016 08:39:13 PM (8 years ago)
Author:
SergeyBiryukov
Message:

REST API: Remove two duplicate strings, use the ones we already have.

See #38791.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php

    r39250 r39252  
    342342        $comment = get_comment( $id );
    343343        if ( empty( $comment ) ) {
    344             return new WP_Error( 'rest_comment_invalid_id', __( 'Invalid comment id.' ), array( 'status' => 404 ) );
     344            return new WP_Error( 'rest_comment_invalid_id', __( 'Invalid comment ID.' ), array( 'status' => 404 ) );
    345345        }
    346346
     
    348348            $post = get_post( $comment->comment_post_ID );
    349349            if ( empty( $post ) ) {
    350                 return new WP_Error( 'rest_post_invalid_id', __( 'Invalid post id.' ), array( 'status' => 404 ) );
     350                return new WP_Error( 'rest_post_invalid_id', __( 'Invalid post ID.' ), array( 'status' => 404 ) );
    351351            }
    352352        }
     
    612612
    613613        if ( empty( $comment ) ) {
    614             return new WP_Error( 'rest_comment_invalid_id', __( 'Invalid comment id.' ), array( 'status' => 404 ) );
     614            return new WP_Error( 'rest_comment_invalid_id', __( 'Invalid comment ID.' ), array( 'status' => 404 ) );
    615615        }
    616616
     
    702702
    703703        if ( ! $comment ) {
    704             return new WP_Error( 'rest_comment_invalid_id', __( 'Invalid comment id.' ), array( 'status' => 404 ) );
     704            return new WP_Error( 'rest_comment_invalid_id', __( 'Invalid comment ID.' ), array( 'status' => 404 ) );
    705705        }
    706706
     
    727727
    728728        if ( empty( $comment ) ) {
    729             return new WP_Error( 'rest_comment_invalid_id', __( 'Invalid comment id.' ), array( 'status' => 404 ) );
     729            return new WP_Error( 'rest_comment_invalid_id', __( 'Invalid comment ID.' ), array( 'status' => 404 ) );
    730730        }
    731731
Note: See TracChangeset for help on using the changeset viewer.