diff options
Diffstat (limited to 'apps')
-rw-r--r-- | apps/files_sharing/lib/mountprovider.php | 3 | ||||
-rw-r--r-- | apps/files_sharing/lib/sharedstorage.php | 15 |
2 files changed, 16 insertions, 2 deletions
diff --git a/apps/files_sharing/lib/mountprovider.php b/apps/files_sharing/lib/mountprovider.php index 14a79625993..458e7f2619b 100644 --- a/apps/files_sharing/lib/mountprovider.php +++ b/apps/files_sharing/lib/mountprovider.php @@ -69,12 +69,11 @@ class MountProvider implements IMountProvider { // for updating etags for the share owner when we make changes to this share. $ownerPropagator = $this->propagationManager->getChangePropagator($share['uid_owner']); - // for updating our etags when changes are made to the share from the owners side (probably indirectly by us trough another share) - $this->propagationManager->listenToOwnerChanges($share['uid_owner'], $user->getUID()); return new SharedMount( '\OC\Files\Storage\Shared', '/' . $user->getUID() . '/' . $share['file_target'], array( + 'propagationManager' => $this->propagationManager, 'propagator' => $ownerPropagator, 'share' => $share, 'user' => $user->getUID() diff --git a/apps/files_sharing/lib/sharedstorage.php b/apps/files_sharing/lib/sharedstorage.php index 1ac401f3cf8..47f3bcf7602 100644 --- a/apps/files_sharing/lib/sharedstorage.php +++ b/apps/files_sharing/lib/sharedstorage.php @@ -50,13 +50,28 @@ class Shared extends \OC\Files\Storage\Common implements ISharedStorage { */ private $ownerView; + /** + * @var \OCA\Files_Sharing\Propagation\PropagationManager + */ + private $propagationManager; + + /** + * @var string + */ + private $user; + public function __construct($arguments) { $this->share = $arguments['share']; $this->ownerView = $arguments['ownerView']; + $this->propagationManager = $arguments['propagationManager']; + $this->user = $arguments['user']; } private function init() { Filesystem::initMountPoints($this->share['uid_owner']); + + // for updating our etags when changes are made to the share from the owners side (probably indirectly by us trough another share) + $this->propagationManager->listenToOwnerChanges($this->share['uid_owner'], $this->user); } /** |