From 80753ed1b69690b3fbe52cb94d02cacc1396c0a7 Mon Sep 17 00:00:00 2001 From: Philipp Date: Sat, 2 Oct 2021 22:20:39 +0200 Subject: [PATCH] Remove disturbing/superfluous logging messages --- src/Core/Session/Handler/Cache.php | 13 ++----------- src/Factory/SessionFactory.php | 2 +- src/Network/GuzzleResponse.php | 1 - 3 files changed, 3 insertions(+), 13 deletions(-) diff --git a/src/Core/Session/Handler/Cache.php b/src/Core/Session/Handler/Cache.php index 8bf7f9364..dc1bfa6b7 100644 --- a/src/Core/Session/Handler/Cache.php +++ b/src/Core/Session/Handler/Cache.php @@ -23,7 +23,6 @@ namespace Friendica\Core\Session\Handler; use Friendica\Core\Cache\ICache; use Friendica\Core\Session; -use Psr\Log\LoggerInterface; use SessionHandlerInterface; /** @@ -33,16 +32,10 @@ class Cache implements SessionHandlerInterface { /** @var ICache */ private $cache; - /** @var LoggerInterface */ - private $logger; - /** @var array The $_SERVER array */ - private $server; - public function __construct(ICache $cache, LoggerInterface $logger, array $server) + public function __construct(ICache $cache) { - $this->cache = $cache; - $this->logger = $logger; - $this->server = $server; + $this->cache = $cache; } public function open($save_path, $session_name) @@ -62,8 +55,6 @@ class Cache implements SessionHandlerInterface return $data; } - $this->logger->notice('no data for session', ['session_id' => $session_id, 'uri' => $this->server['REQUEST_URI'] ?? '']); - return ''; } diff --git a/src/Factory/SessionFactory.php b/src/Factory/SessionFactory.php index f4d2dd89f..491573033 100644 --- a/src/Factory/SessionFactory.php +++ b/src/Factory/SessionFactory.php @@ -77,7 +77,7 @@ class SessionFactory if ($config->get('system', 'cache_driver') === Type::DATABASE) { $handler = new Session\Handler\Database($dba, $logger, $server); } else { - $handler = new Session\Handler\Cache($cache, $logger, $server); + $handler = new Session\Handler\Cache($cache); } break; } diff --git a/src/Network/GuzzleResponse.php b/src/Network/GuzzleResponse.php index 3b41f6f65..d5afb4ca6 100644 --- a/src/Network/GuzzleResponse.php +++ b/src/Network/GuzzleResponse.php @@ -68,7 +68,6 @@ class GuzzleResponse extends Response implements IHTTPResult, ResponseInterface } if (!$this->isSuccess) { - Logger::notice('http error', ['url' => $this->url, 'code' => $this->getReturnCode(), 'error' => $this->error, 'callstack' => System::callstack(20)]); Logger::debug('debug', ['info' => $this->getHeaders()]); }