[wp-trac] [WordPress Trac] #14789: Inconsitency in 'all' hook invocation
WordPress Trac
wp-trac at lists.automattic.com
Tue Sep 7 01:41:33 UTC 2010
#14789: Inconsitency in 'all' hook invocation
--------------------------+-------------------------------------------------
Reporter: hakre | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 3.0.1
Severity: normal | Keywords: has-patch
--------------------------+-------------------------------------------------
The 'all' hook (catchall hook for any hook name) is getting inconsistently
called depending on how the concrete hook is being invoked: by
apply_filters, apply_filters_ref_array, do_action or do_action_ref_array.
In the simple cases (apply_filters, do_action), the hook will get all
parameters passed, in the ..._ref_array cases, the hook will get only two
parameters passed in which the first parameter is the name of the hook
(a.k.a. tag) and the second parameter is an array of all other parameters.
Every 'all' hook-function-callbacks should be called in the same way
regardless whether which of the four invocation functions have been used
on that pointcut.
Additionally all four routines share a lot of the same code which could
benefit of a refactoring.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/14789>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list