diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2019-10-28 20:27:59 +0100 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2019-11-01 08:53:18 +0100 |
commit | 1ac57e76fadc1cf47f27134e98197068850df469 (patch) | |
tree | 81c098daaa680e92980a29627aa2a07e450d35e6 /apps/files_sharing/lib/AppInfo | |
parent | 4326b03b13f858a38a4b0703aaaecf839fc0c03a (diff) | |
download | nextcloud-server-1ac57e76fadc1cf47f27134e98197068850df469.tar.gz nextcloud-server-1ac57e76fadc1cf47f27134e98197068850df469.zip |
Add notification for shares about to expire
Introduces a new command that will create notifications for users if
they have shares that will expire the next day.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'apps/files_sharing/lib/AppInfo')
-rw-r--r-- | apps/files_sharing/lib/AppInfo/Application.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/files_sharing/lib/AppInfo/Application.php b/apps/files_sharing/lib/AppInfo/Application.php index d1c5294dae9..bba87ba991f 100644 --- a/apps/files_sharing/lib/AppInfo/Application.php +++ b/apps/files_sharing/lib/AppInfo/Application.php @@ -32,6 +32,7 @@ namespace OCA\Files_Sharing\AppInfo; use OCA\Files_Sharing\Middleware\OCSShareAPIMiddleware; use OCA\Files_Sharing\Middleware\ShareInfoMiddleware; use OCA\Files_Sharing\MountProvider; +use OCA\Files_Sharing\Notification\Notifier; use OCP\AppFramework\App; use OC\AppFramework\Utility\SimpleContainer; use OCA\Files_Sharing\Controller\ExternalSharesController; @@ -164,6 +165,10 @@ class Application extends App { * Register capabilities */ $container->registerCapability(Capabilities::class); + + /** @var \OCP\Notification\IManager $notifications */ + $notifications = $container->query(\OCP\Notification\IManager::class); + $notifications->registerNotifierService(Notifier::class); } public function registerMountProviders() { |