From 563fa568d35c0a5ecd7e87184b5945d2a9c6bd4e Mon Sep 17 00:00:00 2001 From: Benjamin Frueh Date: Thu, 13 Nov 2025 14:59:08 +0100 Subject: [PATCH] fix: Clear mount cache when file storage changes during move Signed-off-by: Benjamin Frueh --- lib/private/Files/Cache/Cache.php | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/private/Files/Cache/Cache.php b/lib/private/Files/Cache/Cache.php index dbbdd08d1ca..b99370779d7 100644 --- a/lib/private/Files/Cache/Cache.php +++ b/lib/private/Files/Cache/Cache.php @@ -775,6 +775,7 @@ class Cache implements ICache { $this->connection->commit(); if ($sourceCache->getNumericStorageId() !== $this->getNumericStorageId()) { + \OCP\Server::get(\OCP\Files\Config\IUserMountCache::class)->clear(); $this->eventDispatcher->dispatchTyped(new CacheEntryRemovedEvent($this->storage, $sourcePath, $sourceId, $sourceCache->getNumericStorageId())); $event = new CacheEntryInsertedEvent($this->storage, $targetPath, $sourceId, $this->getNumericStorageId()); $this->eventDispatcher->dispatch(CacheInsertEvent::class, $event);