[wp-trac] [WordPress Trac] #39732: Allowing wp_update_comment() to return WP_Error

WordPress Trac noreply at wordpress.org
Mon Jun 29 23:41:12 UTC 2020


#39732: Allowing wp_update_comment() to return WP_Error
-------------------------------------------------+-------------------------
 Reporter:  enrico.sorcinelli                    |       Owner:
                                                 |  enrico.sorcinelli
     Type:  enhancement                          |      Status:  closed
 Priority:  normal                               |   Milestone:  5.5
Component:  Comments                             |     Version:  4.8
 Severity:  normal                               |  Resolution:  fixed
 Keywords:  has-patch has-unit-tests needs-dev-  |     Focuses:
  note commit                                    |
-------------------------------------------------+-------------------------

Comment (by SergeyBiryukov):

 In [changeset:"48218" 48218]:
 {{{
 #!CommitTicketReference repository="" revision="48218"
 Comments: Make `wp_update_comment()` return a `WP_Error` object for a
 canceled update, if `$wp_error` parameter is true.

 Remove redundant checks for `wp_update_comment()` results being `false`,
 as the function always returns a `WP_Error` object now if `$wp_error` is
 true.

 Follow-up to [48154], [48215], [48216].

 See #39732.
 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/39732#comment:50>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list