mirror of
https://github.com/felixfoertsch/wordpress-dev-env.git
synced 2026-04-18 07:18:43 +02:00
Initial commit
This commit is contained in:
25
wordpress_plugins/query-monitor-extend-version-1.0/classes/Collector.php
Executable file
25
wordpress_plugins/query-monitor-extend-version-1.0/classes/Collector.php
Executable file
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
/**
|
||||
* Abstract data collector.
|
||||
*
|
||||
* @package query-monitor-extend
|
||||
*/
|
||||
|
||||
abstract class QMX_Collector extends QM_Collector {
|
||||
|
||||
protected static $hide_qmx = null;
|
||||
|
||||
public static function hide_qmx() {
|
||||
if ( null === self::$hide_qmx ) {
|
||||
self::$hide_qmx = ( defined( 'QMX_HIDE_SELF' ) && QMX_HIDE_SELF );
|
||||
}
|
||||
|
||||
return self::$hide_qmx;
|
||||
}
|
||||
|
||||
public function filter_remove_qmx( array $item ) {
|
||||
$component = $item['trace']->get_component();
|
||||
return ( 'query-monitor-extend' !== $component->context );
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user