Please Add Hook to init_panels
-
I am working on a Debug Bar extension and have to use static methods within my class because there is no “hey, debug bar is about to get started” hook.
The earliest place I can find to latch onto Debug Bar is with the ‘debug_bar_panels’ filter, but that is a filter not a hook and thus shouldn’t really be used to perform an action. Like “hey, invoke my class and setup the filters”.
I can hack around this, but it would be much better to have something like this:
function init_panels() {
do_action(‘debug_bar_init_panels_starting’);
…
$this->panels = apply_filters(‘debug_bar_panels’, $this->panels);
}
The topic ‘Please Add Hook to init_panels’ is closed to new replies.