Changeset 6499 for trunk/src/includes/replies/functions.php
- Timestamp:
- 06/08/2017 04:06:24 AM (9 years ago)
- File:
-
- 1 edited
-
trunk/src/includes/replies/functions.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/includes/replies/functions.php
r6477 r6499 43 43 44 44 // Insert reply 45 $reply_id = wp_insert_post( $reply_data );45 $reply_id = wp_insert_post( $reply_data, false ); 46 46 47 47 // Bail if no reply was added … … 404 404 405 405 // Insert reply 406 $reply_id = wp_insert_post( $reply_data );406 $reply_id = wp_insert_post( $reply_data, true ); 407 407 408 408 /** No Errors *************************************************************/ … … 492 492 /** Errors ****************************************************************/ 493 493 494 // WP_Error 495 } elseif ( is_wp_error( $reply_id ) ) { 496 bbp_add_error( 'bbp_reply_error', sprintf( __( '<strong>ERROR</strong>: The following problem(s) occurred: %s', 'bbpress' ), $reply_id->get_error_message() ) ); 497 498 // Generic error 494 499 } else { 495 $append_error = ( is_wp_error( $reply_id ) && $reply_id->get_error_message() ) ? $reply_id->get_error_message() . ' ' : ''; 496 bbp_add_error( 'bbp_reply_error', __( '<strong>ERROR</strong>: The following problem(s) have been found with your reply:' . $append_error . 'Please try again.', 'bbpress' ) ); 500 bbp_add_error( 'bbp_reply_error', __( '<strong>ERROR</strong>: The reply was not created.', 'bbpress' ) ); 497 501 } 498 502 }
Note: See TracChangeset
for help on using the changeset viewer.