[wp-trac] [WordPress Trac] #40352: WP REST API, Comments Not Triggering 'comment_post'
WordPress Trac
noreply at wordpress.org
Wed Apr 5 09:49:33 UTC 2017
#40352: WP REST API, Comments Not Triggering 'comment_post'
--------------------------+------------------------------
Reporter: stickypixel | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Comments | Version: 4.7
Severity: normal | Resolution:
Keywords: dev-feedback | Focuses: rest-api
--------------------------+------------------------------
Changes (by johnbillion):
* keywords: => dev-feedback
* component: REST API => Comments
Comment:
Thanks for the ticket @stickypixel.
This is caused by the comment controller calling `wp_insert_comment()`
directly, instead of calling `wp_new_comment()`, which is the function
that triggers the `comment_post` action and is used throughout the rest of
the admin area.
This might be an intentional design decision by the REST API team.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/40352#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list