summaryrefslogtreecommitdiffstats
path: root/apps/updatenotification/lib
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2021-04-16 12:39:08 +0200
committerRoeland Jago Douma <roeland@famdouma.nl>2021-04-16 13:56:28 +0200
commit0593b039fc3387e76aa9798bcbf93bda8466667b (patch)
treea7ffc867435e8d905494aa6c1c3e0a403521a013 /apps/updatenotification/lib
parentfc1161722282ecc2d3a40627042b3dac418126cd (diff)
downloadnextcloud-server-0593b039fc3387e76aa9798bcbf93bda8466667b.tar.gz
nextcloud-server-0593b039fc3387e76aa9798bcbf93bda8466667b.zip
Move over notification to new registration
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'apps/updatenotification/lib')
-rw-r--r--apps/updatenotification/lib/AppInfo/Application.php6
1 files changed, 1 insertions, 5 deletions
diff --git a/apps/updatenotification/lib/AppInfo/Application.php b/apps/updatenotification/lib/AppInfo/Application.php
index 54d6444236a..42c725caf8c 100644
--- a/apps/updatenotification/lib/AppInfo/Application.php
+++ b/apps/updatenotification/lib/AppInfo/Application.php
@@ -43,7 +43,6 @@ use OCP\IGroupManager;
use OCP\ILogger;
use OCP\IUser;
use OCP\IUserSession;
-use OCP\Notification\IManager as INotificationManager;
use OCP\Util;
class Application extends App implements IBootstrap {
@@ -52,11 +51,11 @@ class Application extends App implements IBootstrap {
}
public function register(IRegistrationContext $context): void {
+ $context->registerNotifierService(Notifier::class);
}
public function boot(IBootContext $context): void {
$context->injectFn(function (IConfig $config,
- INotificationManager $notificationsManager,
IUserSession $userSession,
IAppManager $appManager,
IGroupManager $groupManager,
@@ -67,9 +66,6 @@ class Application extends App implements IBootstrap {
return;
}
- // Always register the notifier, so background jobs (without a user) can send push notifications
- $notificationsManager->registerNotifierService(Notifier::class);
-
$user = $userSession->getUser();
if (!$user instanceof IUser) {
// Nothing to do for guests