]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix path match
authorJoas Schilling <nickvergessen@owncloud.com>
Tue, 2 Feb 2016 10:12:16 +0000 (11:12 +0100)
committerJoas Schilling <nickvergessen@owncloud.com>
Tue, 2 Feb 2016 10:12:16 +0000 (11:12 +0100)
apps/systemtags/activity/listener.php
apps/systemtags/appinfo/app.php

index 3afbde7a669b7b54109da3684701562bd33ed16f..9b6597119c6c79b4fb7d1f791cb0055949c09203 100644 (file)
@@ -163,7 +163,7 @@ class Listener {
                                /** @var Node $node */
                                $node = array_shift($nodes);
                                $path = $node->getPath();
-                               if (strpos($path, '/' . $owner . '/files') === 0) {
+                               if (strpos($path, '/' . $owner . '/files/') === 0) {
                                        $path = substr($path, strlen('/' . $owner . '/files'));
                                }
                                // Get all users that have access to the mount point
index d948f4857f6950af3e8c632e1f5a355cba71a3fb..0bb57e1227b142f894deb6885d111e6089aeedaf 100644 (file)
@@ -48,11 +48,14 @@ $eventDispatcher->addListener(
 $activityManager = \OC::$server->getActivityManager();
 $activityManager->registerExtension(function() {
        $application = new \OCP\AppFramework\App('systemtags');
-       return $application->getContainer()->query('OCA\SystemTags\Activity\Extension');
+       /** @var \OCA\SystemTags\Activity\Extension $extension */
+       $extension = $application->getContainer()->query('OCA\SystemTags\Activity\Extension');
+       return $extension;
 });
 
 $managerListener = function(ManagerEvent $event) use ($activityManager) {
        $application = new \OCP\AppFramework\App('systemtags');
+       /** @var \OCA\SystemTags\Activity\Listener $listener */
        $listener = $application->getContainer()->query('OCA\SystemTags\Activity\Listener');
        $listener->event($event);
 };
@@ -63,6 +66,7 @@ $eventDispatcher->addListener(ManagerEvent::EVENT_UPDATE, $managerListener);
 
 $mapperListener = function(MapperEvent $event) use ($activityManager) {
        $application = new \OCP\AppFramework\App('systemtags');
+       /** @var \OCA\SystemTags\Activity\Listener $listener */
        $listener = $application->getContainer()->query('OCA\SystemTags\Activity\Listener');
        $listener->mapperEvent($event);
 };