Pass the old term_taxonomy ids to the action in set_object_terms so plugins know what was before. Fixes #10962 props simonwheatley.

git-svn-id: http://svn.automattic.com/wordpress/trunk@12261 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
westi 2009-11-22 22:33:45 +00:00
parent b912aa2012
commit 693451e75f
1 changed files with 1 additions and 1 deletions

View File

@ -1518,7 +1518,7 @@ function wp_set_object_terms($object_id, $terms, $taxonomy, $append = false) {
$wpdb->query("INSERT INTO $wpdb->term_relationships (object_id, term_taxonomy_id, term_order) VALUES " . join(',', $values) . " ON DUPLICATE KEY UPDATE term_order = VALUES(term_order)");
}
do_action('set_object_terms', $object_id, $terms, $tt_ids, $taxonomy, $append);
do_action('set_object_terms', $object_id, $terms, $tt_ids, $taxonomy, $append, $old_tt_ids);
return $tt_ids;
}