Capture last db error. Pass it in WP_Error data when term inserts fail. Fix typo in WP_Ajax_Response

git-svn-id: https://develop.svn.wordpress.org/trunk@7431 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren
2008-03-20 23:34:32 +00:00
parent 2553a64d19
commit 39a2681bc7
3 changed files with 5 additions and 4 deletions

View File

@@ -764,7 +764,7 @@ class WP_Ajax_Response {
$response .= "<wp_error_data code='$code'$class>";
if ( is_scalar($error_data) ) {
$response .= "<![CDATA[$v]]>";
$response .= "<![CDATA[$error_data]]>";
} elseif ( is_array($error_data) ) {
foreach ( $error_data as $k => $v )
$response .= "<$k><![CDATA[$v]]></$k>";