Remove default feed function when adding new function to hook. fixes #6970
git-svn-id: http://svn.automattic.com/wordpress/trunk@8179 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
316e26ee39
commit
34a726ae12
|
@ -31,7 +31,8 @@ function add_feed($feedname, $function) {
|
|||
$wp_rewrite->feeds[] = $feedname;
|
||||
}
|
||||
$hook = 'do_feed_' . $feedname;
|
||||
remove_action($hook, $function, 10, 1);
|
||||
// Remove default function hook
|
||||
remove_action($hook, $hook, 10, 1);
|
||||
add_action($hook, $function, 10, 1);
|
||||
return $hook;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue