[wp-trac] [WordPress Trac] #28978: wp_send_json_error() should support WP_Error objects
WordPress Trac
noreply at wordpress.org
Fri Sep 12 06:36:55 UTC 2014
#28978: wp_send_json_error() should support WP_Error objects
---------------------------------------------+----------------------------
Reporter: danielbachhuber | Owner: paulschreiber
Type: enhancement | Status: assigned
Priority: normal | Milestone: 4.1
Component: General | Version:
Severity: normal | Resolution:
Keywords: good-first-bug has-patch commit | Focuses:
---------------------------------------------+----------------------------
Comment (by rmccue):
Any chance we can move the WP_Error stuff out to a separate function? That
way we can use it in the REST API easily (`wp_send_json_error` itself is a
no-go, as it isn't re-entrant).
(Also, we could consider adding a filter there in case someone does want
to add the data back for debugging or similar.)
--
Ticket URL: <https://core.trac.wordpress.org/ticket/28978#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list