SILENT KILLERPanel

Current Path: > home > transcarter > > www > wp-content > plugins > query-monitor > collectors


Operation   : Linux host59.registrar-servers.com 4.18.0-513.18.1.lve.2.el8.x86_64 #1 SMP Sat Mar 30 15:36:11 UTC 2024 x86_64
Software     : Apache
Server IP    : 198.54.126.42 | Your IP: 216.73.216.135
Domains      : 1034 Domain(s)
Permission   : [ 0755 ]

Files and Folders in: /home/transcarter//www/wp-content/plugins/query-monitor/collectors

NameTypeSizeLast ModifiedActions
admin.php File 3426 bytes July 17 2025 21:05:45.
assets_scripts.php File 1215 bytes July 17 2025 21:05:45.
assets_styles.php File 862 bytes July 17 2025 21:05:45.
block_editor.php File 5528 bytes July 17 2025 21:05:45.
cache.php File 3576 bytes July 17 2025 21:05:45.
caps.php File 7352 bytes July 17 2025 21:05:45.
conditionals.php File 2803 bytes July 17 2025 21:05:45.
db_callers.php File 1140 bytes July 17 2025 21:05:45.
db_components.php File 1175 bytes July 17 2025 21:05:45.
db_dupes.php File 3498 bytes July 17 2025 21:05:45.
db_queries.php File 6415 bytes July 17 2025 21:05:45.
debug_bar.php File 2757 bytes July 17 2025 21:05:45.
doing_it_wrong.php File 12778 bytes July 17 2025 21:05:45.
environment.php File 9074 bytes July 17 2025 21:05:45.
hooks.php File 2019 bytes July 17 2025 21:05:45.
http.php File 11557 bytes July 17 2025 21:05:45.
languages.php File 7552 bytes July 17 2025 21:05:45.
logger.php File 7945 bytes July 17 2025 21:05:45.
multisite.php File 1631 bytes July 17 2025 21:05:45.
overview.php File 2845 bytes July 17 2025 21:05:45.
php_errors.php File 15565 bytes July 17 2025 21:05:45.
raw_request.php File 2424 bytes July 17 2025 21:05:45.
redirects.php File 1365 bytes July 17 2025 21:05:45.
request.php File 7325 bytes July 17 2025 21:05:45.
theme.php File 17934 bytes July 17 2025 21:05:45.
timing.php File 4448 bytes July 17 2025 21:05:45.
transients.php File 3010 bytes July 17 2025 21:05:45.

Reading File: /home/transcarter//www/wp-content/plugins/query-monitor/collectors/debug_bar.php

<?php declare(strict_types = 1);
/**
 * Mock 'Debug Bar' data collector.
 *
 * @package query-monitor
 */

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

final class QM_Collector_Debug_Bar extends QM_Collector {

	/**
	 * @var string
	 */
	public $id = 'debug_bar';

	/**
	 * @var Debug_Bar_Panel|null
	 */
	private $panel = null;

	/**
	 * @param Debug_Bar_Panel $panel
	 * @return void
	 */
	public function set_panel( Debug_Bar_Panel $panel ) {
		$this->panel = $panel;
	}

	/**
	 * @return Debug_Bar_Panel|null
	 */
	public function get_panel() {
		return $this->panel;
	}

	/**
	 * @return void
	 */
	public function process() {
		$this->get_panel()->prerender();
	}

	/**
	 * @return bool
	 */
	public function is_visible() {
		return $this->get_panel()->is_visible();
	}

	/**
	 * @return void
	 */
	public function render() {
		$this->get_panel()->render();
	}

}

/**
 * @return void
 */
function register_qm_collectors_debug_bar() {

	global $debug_bar;

	$debug_bar_exists = isset( $GLOBALS['debug_bar'] ) && ( $GLOBALS['debug_bar'] instanceof Debug_Bar );

	if ( $debug_bar_exists || qm_debug_bar_being_activated() ) {
		return;
	}

	$collectors = QM_Collectors::init();

	$debug_bar = new Debug_Bar();
	$redundant = array(
		'debug_bar_actions_addon_panel', // Debug Bar Actions and Filters Addon
		'debug_bar_remote_requests_panel', // Debug Bar Remote Requests
		'debug_bar_screen_info_panel', // Debug Bar Screen Info
		'ps_listdeps_debug_bar_panel', // Debug Bar List Script & Style Dependencies
	);

	foreach ( $debug_bar->panels as $panel ) {
		$panel_id = strtolower( sanitize_html_class( get_class( $panel ) ) );

		if ( in_array( $panel_id, $redundant, true ) ) {
			continue;
		}

		$collector = new QM_Collector_Debug_Bar();
		$collector->set_id( "debug_bar_{$panel_id}" );
		$collector->set_panel( $panel );

		$collectors->add( $collector );
	}

}

/**
 * @return bool
 */
function qm_debug_bar_being_activated() {
	// phpcs:disable

	if ( ! is_admin() ) {
		return false;
	}

	if ( ! isset( $_REQUEST['action'] ) ) {
		return false;
	}

	if ( isset( $_GET['action'] ) ) {

		if ( ! isset( $_GET['plugin'] ) || ! isset( $_GET['_wpnonce'] ) ) {
			return false;
		}

		if ( 'activate' === $_GET['action'] && false !== strpos( wp_unslash( $_GET['plugin'] ), 'debug-bar.php' ) ) {
			return true;
		}

	} elseif ( isset( $_POST['action'] ) ) {

		if ( ! isset( $_POST['checked'] ) || ! is_array( $_POST['checked'] ) || ! isset( $_POST['_wpnonce'] ) ) {
			return false;
		}

		if ( 'activate-selected' === wp_unslash( $_POST['action'] ) && in_array( 'debug-bar/debug-bar.php', wp_unslash( $_POST['checked'] ), true ) ) {
			return true;
		}

	}

	return false;
	// phpcs:enable
}

add_action( 'init', 'register_qm_collectors_debug_bar' );

SILENT KILLER Tool