/var/www/vhosts/ihelp.ro/httpdocs/vendor/cakephp/debug_kit/src
NameSizeModeActions
Cache/-0755rm
Command/-0755rm
Controller/-0755rm
Database/-0755rm
Log/-0755rm
Mailer/-0755rm
Middleware/-0755rm
Model/-0755rm
Panel/-0755rm
View/-0755rm
DebugInclude.php53900644editdlrm
DebugMemory.php28070644editdlrm
DebugPanel.php26610644editdlrm
DebugSql.php57620644editdlrm
DebugTimer.php59130644editdlrm
Plugin.php39810644editdlrm
ToolbarService.php118320644editdlrm
Edit: /var/www/vhosts/ihelp.ro/httpdocs/vendor/cakephp/debug_kit/src/Plugin.php (3981B)
isEnabled()) { return; } $this->service = $service; $this->setDeprecationHandler($service); // will load `config/bootstrap.php`. parent::bootstrap($app); } /** * Add middleware for the plugin. * * @param \Cake\Http\MiddlewareQueue $middlewareQueue The middleware queue to update. * @return \Cake\Http\MiddlewareQueue */ public function middleware(MiddlewareQueue $middlewareQueue): MiddlewareQueue { // Only insert middleware if Toolbar Service is available (not in phpunit run) if ($this->service) { $middlewareQueue->insertAt(0, new DebugKitMiddleware($this->service)); } return $middlewareQueue; } /** * Add console commands for the plugin. * * @param \Cake\Console\CommandCollection $commands The command collection to update * @return \Cake\Console\CommandCollection */ public function console(CommandCollection $commands): CommandCollection { return $commands->add('benchmark', BenchmarkCommand::class); } /** * set deprecation handler * * @param \DebugKit\ToolbarService $service The toolbar service instance * @return void */ public function setDeprecationHandler($service) { if (!empty($service->getConfig('panels')['DebugKit.Deprecations'])) { EventManager::instance()->on('Error.beforeRender', function (EventInterface $event, PhpError $error) { $code = $error->getCode(); if ($code !== E_USER_DEPRECATED && $code !== E_DEPRECATED) { return; } $file = $error->getFile(); $line = $error->getLine(); // Extract the line/file from the message as deprecationWarning // will calculate the application frame when generating the message. preg_match('/\\n([^\n,]+?), line: (\d+)\\n/', $error->getMessage(), $matches); if ($matches) { $file = $matches[1]; $line = $matches[2]; } DeprecationsPanel::addDeprecatedError([ 'code' => $code, 'message' => $error->getMessage(), 'file' => $file, 'line' => $line, ]); $event->stopPropagation(); }); } } }