Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/spreed.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2020-07-31 17:25:33 +0300
committerJoas Schilling <coding@schilljs.com>2020-08-03 14:38:45 +0300
commitb6829acbaabb2e323fb0b0c12d0251485d2e8781 (patch)
treef7284c9bddd6ba39187e4fd58b15d8ac0751336e /lib/Notification
parentdea5040713e0a574d5bf95152a10db656ac75757 (diff)
Move to Psr\Log\LoggerInterface
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/Notification')
-rw-r--r--lib/Notification/Listener.php18
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/Notification/Listener.php b/lib/Notification/Listener.php
index 9ae172c73..02cd0aaf7 100644
--- a/lib/Notification/Listener.php
+++ b/lib/Notification/Listener.php
@@ -30,9 +30,9 @@ use OCA\Talk\Room;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\EventDispatcher\IEventDispatcher;
use OCP\Notification\IManager;
-use OCP\ILogger;
use OCP\IUser;
use OCP\IUserSession;
+use Psr\Log\LoggerInterface;
class Listener {
@@ -44,7 +44,7 @@ class Listener {
protected $userSession;
/** @var ITimeFactory */
protected $timeFactory;
- /** @var ILogger */
+ /** @var LoggerInterface */
protected $logger;
/** @var bool */
@@ -54,7 +54,7 @@ class Listener {
IEventDispatcher $dispatcher,
IUserSession $userSession,
ITimeFactory $timeFactory,
- ILogger $logger) {
+ LoggerInterface $logger) {
$this->notificationManager = $notificationManager;
$this->dispatcher = $dispatcher;
$this->userSession = $userSession;
@@ -129,7 +129,7 @@ class Listener {
'actorId' => $actor->getUID(),
]);
} catch (\InvalidArgumentException $e) {
- $this->logger->logException($e, ['app' => 'spreed']);
+ $this->logger->error($e->getMessage(), ['exception' => $e]);
if ($shouldFlush) {
$this->notificationManager->flush();
}
@@ -146,7 +146,7 @@ class Listener {
$notification->setUser($participant['userId']);
$this->notificationManager->notify($notification);
} catch (\InvalidArgumentException $e) {
- $this->logger->logException($e, ['app' => 'spreed']);
+ $this->logger->error($e->getMessage(), ['exception' => $e]);
}
}
@@ -174,7 +174,7 @@ class Listener {
->setSubject('invitation');
$this->notificationManager->markProcessed($notification);
} catch (\InvalidArgumentException $e) {
- $this->logger->logException($e, ['app' => 'spreed']);
+ $this->logger->error($e->getMessage(), ['exception' => $e]);
return;
}
}
@@ -229,7 +229,7 @@ class Listener {
])
->setDateTime($dateTime);
} catch (\InvalidArgumentException $e) {
- $this->logger->logException($e, ['app' => 'spreed']);
+ $this->logger->error($e->getMessage(), ['exception' => $e]);
if ($shouldFlush) {
$this->notificationManager->flush();
}
@@ -246,7 +246,7 @@ class Listener {
$notification->setUser($userId);
$this->notificationManager->notify($notification);
} catch (\InvalidArgumentException $e) {
- $this->logger->logException($e, ['app' => 'spreed']);
+ $this->logger->error($e->getMessage(), ['exception' => $e]);
}
}
@@ -274,7 +274,7 @@ class Listener {
->setSubject('call');
$this->notificationManager->markProcessed($notification);
} catch (\InvalidArgumentException $e) {
- $this->logger->logException($e, ['app' => 'spreed']);
+ $this->logger->error($e->getMessage(), ['exception' => $e]);
return;
}
}