From c0ce272e9c3a94ff98081c4f90a31ca611d28323 Mon Sep 17 00:00:00 2001 From: Côme Chilliet Date: Thu, 8 Feb 2024 15:47:39 +0100 Subject: chore: Migrate away from OC::$server->getLogger MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Côme Chilliet --- lib/public/AppFramework/App.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'lib/public/AppFramework') diff --git a/lib/public/AppFramework/App.php b/lib/public/AppFramework/App.php index 4d6e9177b78..f62c464ea55 100644 --- a/lib/public/AppFramework/App.php +++ b/lib/public/AppFramework/App.php @@ -38,6 +38,7 @@ use OC\AppFramework\Routing\RouteConfig; use OC\Route\Router; use OC\ServerContainer; use OCP\Route\IRouter; +use Psr\Log\LoggerInterface; /** * Class App @@ -98,8 +99,9 @@ class App { } if (!$setUpViaQuery && $applicationClassName !== \OCP\AppFramework\App::class) { - \OC::$server->getLogger()->logException($e, [ + \OCP\Server::get(LoggerInterface::class)->error($e->getMessage(), [ 'app' => $appName, + 'exception' => $e, ]); } } -- cgit v1.2.3