From 1a130a9135fb25c54be36b4fb33da0b636c8437b Mon Sep 17 00:00:00 2001 From: Marcel Klehr Date: Mon, 30 Sep 2024 09:35:32 +0200 Subject: [PATCH] fix(FileListener): Always react to CacheEntryInsertedEvent Signed-off-by: Marcel Klehr --- lib/Db/QueueMapper.php | 2 +- lib/Hooks/FileListener.php | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/Db/QueueMapper.php b/lib/Db/QueueMapper.php index a3cc31ce..54ecb723 100644 --- a/lib/Db/QueueMapper.php +++ b/lib/Db/QueueMapper.php @@ -110,7 +110,7 @@ public function existsQueueItem(string $model, QueueFile $file) : bool { } catch (DoesNotExistException $e) { return false; } catch (MultipleObjectsReturnedException $e) { - return false; + return true; } catch (Exception $e) { return false; } diff --git a/lib/Hooks/FileListener.php b/lib/Hooks/FileListener.php index 5b478a30..54284016 100644 --- a/lib/Hooks/FileListener.php +++ b/lib/Hooks/FileListener.php @@ -218,9 +218,6 @@ public function handle(Event $event): void { if ($node instanceof Folder) { return; } - if (!str_contains($node->getMountPoint()->getMountType(), 'external')) { - return; - } if (in_array($node->getName(), [...Constants::IGNORE_MARKERS_ALL, ...Constants::IGNORE_MARKERS_IMAGE, ...Constants::IGNORE_MARKERS_AUDIO, ...Constants::IGNORE_MARKERS_VIDEO], true)) { $this->resetIgnoreCache($node); $this->postDelete($node->getParent());