Ticket #5342 (closed defect (bug): fixed)
Output WP_Error message when adding categories via AJAX
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Priority: | normal | Milestone: | 2.5 |
| Component: | General | Version: | |
| Severity: | normal | Keywords: | ajax category error |
| Cc: |
Description (last modified by ryan) (diff)
Currently, adding categories via AJAX outputs a generic error message when something goes wrong in wp_insert_category() since that function does not return WP_Error. Let's add an option to wp_insert_category() that tells it to return WP_Error instead of 0. We must maintain returning 0 by default for back-compat reasons.
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

