From b025f07fb7090acfe9d168974b4ce2e66f973e30 Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Wed, 25 Nov 2015 13:53:31 +0100 Subject: Make Cache\Updater per storage --- apps/dav/lib/connector/sabre/file.php | 4 ++-- apps/encryption/lib/migration.php | 2 +- apps/files_trashbin/lib/trashbin.php | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) (limited to 'apps') diff --git a/apps/dav/lib/connector/sabre/file.php b/apps/dav/lib/connector/sabre/file.php index ef7b9891dc9..c66f627c0a3 100644 --- a/apps/dav/lib/connector/sabre/file.php +++ b/apps/dav/lib/connector/sabre/file.php @@ -192,7 +192,7 @@ class File extends Node implements IFile { } // since we skipped the view we need to scan and emit the hooks ourselves - $this->fileView->getUpdater()->update($this->path); + $storage->getUpdater()->update($internalPath); if ($view) { $this->emitPostHooks($exists); @@ -438,7 +438,7 @@ class File extends Node implements IFile { $this->fileView->changeLock($targetPath, ILockingProvider::LOCK_SHARED); // since we skipped the view we need to scan and emit the hooks ourselves - $this->fileView->getUpdater()->update($targetPath); + $targetStorage->getUpdater()->update($targetInternalPath); $this->emitPostHooks($exists, $targetPath); diff --git a/apps/encryption/lib/migration.php b/apps/encryption/lib/migration.php index 1a7c2e9877d..0b691624a00 100644 --- a/apps/encryption/lib/migration.php +++ b/apps/encryption/lib/migration.php @@ -50,7 +50,7 @@ class Migration { */ public function __construct(IConfig $config, View $view, IDBConnection $connection, ILogger $logger) { $this->view = $view; - $this->view->getUpdater()->disable(); + $this->view->disableCacheUpdate(); $this->connection = $connection; $this->moduleId = \OCA\Encryption\Crypto\Encryption::ID; $this->config = $config; diff --git a/apps/files_trashbin/lib/trashbin.php b/apps/files_trashbin/lib/trashbin.php index 8f0fe745a45..94975530799 100644 --- a/apps/files_trashbin/lib/trashbin.php +++ b/apps/files_trashbin/lib/trashbin.php @@ -235,7 +235,7 @@ class Trashbin { return false; } - $ownerView->getUpdater()->rename('/files/' . $ownerPath, $trashPath); + $trashStorage->getUpdater()->renameFromStorage($sourceStorage, $sourceInternalPath, $trashInternalPath); if ($sizeOfAddedFiles !== false) { $size = $sizeOfAddedFiles; @@ -323,7 +323,7 @@ class Trashbin { $result = $targetStorage->moveFromStorage($sourceStorage, $sourceInternalPath, $targetInternalPath); if ($result) { - $view->getUpdater()->rename($source, $target); + $targetStorage->getUpdater()->renameFromStorage($sourceStorage, $sourceInternalPath, $targetInternalPath); } return $result; } @@ -345,7 +345,7 @@ class Trashbin { $result = $targetStorage->copyFromStorage($sourceStorage, $sourceInternalPath, $targetInternalPath); if ($result) { - $view->getUpdater()->update($target); + $targetStorage->getUpdater()->update($targetInternalPath); } return $result; } -- cgit v1.2.3