summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@owncloud.com>2016-02-09 16:02:53 +0100
committerJoas Schilling <nickvergessen@owncloud.com>2016-02-10 08:40:45 +0100
commita4a7cf40a1f8e174d2a45fbf791db2bcada5ce68 (patch)
treed9b552b05569d4ef19a2ece202a7c55691b18774 /apps/files_sharing
parent3ff88c8c84d887c36a5b6587c402bd627bcffdd6 (diff)
downloadnextcloud-server-a4a7cf40a1f8e174d2a45fbf791db2bcada5ce68.tar.gz
nextcloud-server-a4a7cf40a1f8e174d2a45fbf791db2bcada5ce68.zip
Fix the notification API usage
Diffstat (limited to 'apps/files_sharing')
-rw-r--r--apps/files_sharing/api/server2server.php2
-rw-r--r--apps/files_sharing/appinfo/app.php5
2 files changed, 6 insertions, 1 deletions
diff --git a/apps/files_sharing/api/server2server.php b/apps/files_sharing/api/server2server.php
index f15169b74a2..c183c91b5fa 100644
--- a/apps/files_sharing/api/server2server.php
+++ b/apps/files_sharing/api/server2server.php
@@ -94,7 +94,7 @@ class Server2Server {
$notification = $notificationManager->createNotification();
$notification->setApp('files_sharing')
->setUser($shareWith)
- ->setTimestamp(time())
+ ->setDateTime(new \DateTime())
->setObject('remote_share', $remoteId)
->setSubject('remote_share', [$user, trim($name, '/')]);
diff --git a/apps/files_sharing/appinfo/app.php b/apps/files_sharing/appinfo/app.php
index 1d3d4b0f634..29202c15b22 100644
--- a/apps/files_sharing/appinfo/app.php
+++ b/apps/files_sharing/appinfo/app.php
@@ -119,4 +119,9 @@ $manager->registerNotifier(function() {
return new \OCA\Files_Sharing\Notifier(
\OC::$server->getL10NFactory()
);
+}, function() use ($l) {
+ return [
+ 'id' => 'files_sharing',
+ 'name' => $l->t('Federated sharing'),
+ ];
});