Browse Source

Allow checking whether there are notifiers registered

remotes/origin/db-empty-migrate
Joas Schilling 10 years ago
committed by Thomas Müller
parent
commit
c3420fface
  1. 6
      lib/private/notification/imanager.php
  2. 8
      lib/private/notification/manager.php

6
lib/private/notification/imanager.php

@ -53,4 +53,10 @@ interface IManager extends IApp, INotifier {
* @since 8.2.0
*/
public function createNotification();
/**
* @return bool
* @since 8.2.0
*/
public function hasNotifiers();
}

8
lib/private/notification/manager.php

@ -112,6 +112,14 @@ class Manager implements IManager {
return new Notification();
}
/**
* @return bool
* @since 8.2.0
*/
public function hasNotifiers() {
return !empty($this->notifiersClosures);
}
/**
* @param INotification $notification
* @return null

Loading…
Cancel
Save