From f7734ccc89e0c18f152e927c4d4aeda2d768e2a5 Mon Sep 17 00:00:00 2001 From: Tomas Jacik Date: Sun, 10 Jan 2021 14:52:07 +0100 Subject: [PATCH] Removed deprecated Logger log level feature --- .docs/README.md | 7 +------ src/Tracy/Bootstrap.php | 13 ++----------- 2 files changed, 3 insertions(+), 17 deletions(-) diff --git a/.docs/README.md b/.docs/README.md index bcb8522..fd4877d 100644 --- a/.docs/README.md +++ b/.docs/README.md @@ -103,13 +103,8 @@ And add this to your `@layout` footer (before ``): ## Tracy ```php -$logLevel = [ // default (NULL means default) - \Tracy\Logger::CRITICAL, - \Tracy\Logger::EXCEPTION, - \Tracy\Logger::ERROR, -]; $appName = 'PHP Application'; // default (NULL means default) $license = 'your_licence_key'; -\Contributte\NewRelic\Tracy\Bootstrap::init($logLevel, $appName, $license); // all parameters are optional +\Contributte\NewRelic\Tracy\Bootstrap::init($appName, $license); // all parameters are optional ``` diff --git a/src/Tracy/Bootstrap.php b/src/Tracy/Bootstrap.php index 035743a..9aa8ea4 100644 --- a/src/Tracy/Bootstrap.php +++ b/src/Tracy/Bootstrap.php @@ -11,11 +11,10 @@ class Bootstrap { /** - * @param string[]|array|NULL $logLevel (null for default - error and critical) * @param string|NULL $appName * @param string|NULL $license */ - public static function init(?array $logLevel = null, $appName = null, $license = null) + public static function init($appName = null, $license = null) { static::check(); @@ -29,15 +28,7 @@ public static function init(?array $logLevel = null, $appName = null, $license = static::setup($appName, $license); - if ($logLevel === null) { - $logLevel = [ - Logger::CRITICAL, - Logger::EXCEPTION, - Logger::ERROR, - ]; - } - - $logger = new Logger($logLevel); + $logger = new Logger(null); Debugger::setLogger($logger); }