Skip to content

Commit 54efdf2

Browse files
committed
fix(files_reminders): add l10n to constructor of setup check
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
1 parent b4e6080 commit 54efdf2

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

apps/files_reminders/lib/SetupChecks/NeedNotificationsApp.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,14 @@
1010
namespace OCA\DAV\SetupChecks;
1111

1212
use OCP\App\IAppManager;
13+
use OCP\IL10N;
1314
use OCP\SetupCheck\ISetupCheck;
1415
use OCP\SetupCheck\SetupResult;
1516

1617
class NeedNotificationsApp implements ISetupCheck {
1718
public function __construct(
1819
private IAppManager $appManager,
20+
private IL10N $l10n,
1921
) {
2022
}
2123

@@ -28,7 +30,7 @@ public function getCategory(): string {
2830
}
2931

3032
public function run(): SetupResult {
31-
if ($this->appManager->isInstalled('notifications')) {
33+
if ($this->appManager->isEnabledForAnyone('notifications')) {
3234
return SetupResult::success($this->l10n->t('This files_reminder can work properly.'));
3335
} else {
3436
return SetupResult::warning($this->l10n->t('The files_reminder app needs the notification app to work properly. You should either enable notifications or disable files_reminder.'));

0 commit comments

Comments
 (0)