mirror of
git://develop.git.wordpress.org/
synced 2025-01-31 12:29:09 +01:00
s/logio/logIO/. Remove logio calls from the one function in functions-post.php that uses it. functions-post.php is not used by xmlrpc.php exclusively.
git-svn-id: https://develop.svn.wordpress.org/trunk@1920 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
bec4de9e54
commit
7a8b254be0
@ -167,13 +167,9 @@ function wp_set_post_cats($blogid = '1', $post_ID = 0, $post_categories = array(
|
||||
$oldies = printr($old_categories,1);
|
||||
$newbies = printr($post_categories,1);
|
||||
|
||||
logio("O","Old: $oldies\nNew: $newbies\n");
|
||||
|
||||
// Delete any?
|
||||
$delete_cats = array_diff($old_categories,$post_categories);
|
||||
|
||||
logio("O","Delete: " . printr($delete_cats,1));
|
||||
|
||||
if ($delete_cats) {
|
||||
foreach ($delete_cats as $del) {
|
||||
$wpdb->query("
|
||||
@ -181,23 +177,17 @@ function wp_set_post_cats($blogid = '1', $post_ID = 0, $post_categories = array(
|
||||
WHERE category_id = $del
|
||||
AND post_id = $post_ID
|
||||
");
|
||||
|
||||
logio("O","deleting post/cat: $post_ID, $del");
|
||||
}
|
||||
}
|
||||
|
||||
// Add any?
|
||||
$add_cats = array_diff($post_categories, $old_categories);
|
||||
|
||||
logio("O","Add: " . printr($add_cats,1));
|
||||
|
||||
if ($add_cats) {
|
||||
foreach ($add_cats as $new_cat) {
|
||||
$wpdb->query("
|
||||
INSERT INTO $wpdb->post2cat (post_id, category_id)
|
||||
VALUES ($post_ID, $new_cat)");
|
||||
|
||||
logio("O","adding post/cat: $post_ID, $new_cat");
|
||||
}
|
||||
}
|
||||
} // wp_set_post_cats()
|
||||
|
@ -519,7 +519,7 @@ class wp_xmlrpc_server extends IXR_Server {
|
||||
}
|
||||
|
||||
$catnames = $content_struct['categories'];
|
||||
logio('O', 'Post cats: ' . printr($catnames,true));
|
||||
logIO('O', 'Post cats: ' . printr($catnames,true));
|
||||
$post_category = array();
|
||||
|
||||
if ($catnames) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user