Opened 19 years ago
Closed 19 years ago
#5342 closed defect (bug) (fixed)
Output WP_Error message when adding categories via AJAX
| Reported by: | ryan | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | 2.5 |
| Component: | General | Version: | |
| Severity: | normal | Keywords: | ajax category error |
| Cc: | Focuses: |
Description (last modified by )
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 (1)
Change History (3)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
(In [6329]) Output WP_Error message when adding categories via AJAX. fixes #5342