Make WordPress Core


Ignore:
Timestamp:
06/07/2020 09:22:07 AM (4 years ago)
Author:
SergeyBiryukov
Message:

Posts, Post Types: Display a more specific error message when an attachment could not be inserted into the database.

Props shital-patel, Presskopp, ocean90.
Fixes #50325.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/comment.php

    r47887 r47922  
    23062306    if ( ! $wpdb->update( $wpdb->comments, array( 'comment_approved' => $status ), array( 'comment_ID' => $comment_old->comment_ID ) ) ) {
    23072307        if ( $wp_error ) {
    2308             return new WP_Error( 'db_update_error', __( 'Could not update comment status' ), $wpdb->last_error );
     2308            return new WP_Error( 'db_update_error', __( 'Could not update comment status.' ), $wpdb->last_error );
    23092309        } else {
    23102310            return false;
Note: See TracChangeset for help on using the changeset viewer.