Skip to content

Commit 61bb3d0

Browse files
authored
fix(ExAppNotifier): First check if any exapps enabled
To avoid unnecessary work and logs Signed-off-by: Marcel Klehr <[email protected]>
1 parent 8c9da2b commit 61bb3d0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lib/Notifications/ExAppNotifier.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,9 @@ public function getName(): string {
3636
}
3737

3838
public function prepare(INotification $notification, string $languageCode): INotification {
39+
if (count($this->service->getExAppsList()) === 0) {
40+
throw new UnknownNotificationException();
41+
}
3942
$exApp = $this->service->getExApp($notification->getApp());
4043
if ($exApp === null) {
4144
throw new UnknownNotificationException();

0 commit comments

Comments
 (0)