WordPress doesn't like this last hook added to shutdown

This commit is contained in:
Daniel Bachhuber 2016-10-08 05:56:25 -07:00
parent 7be192206e
commit ff802e8de9

View file

@ -304,8 +304,10 @@ class Command {
$this->filter_depth = 1; $this->filter_depth = 1;
} }
if ( 'shutdown' !== $this->focus_hook ) {
WP_CLI::add_wp_hook( $current_filter, array( $this, 'wp_hook_end' ), 9999 ); WP_CLI::add_wp_hook( $current_filter, array( $this, 'wp_hook_end' ), 9999 );
} }
}
/** /**
* Wrap current filter callbacks with a timer * Wrap current filter callbacks with a timer