From 2495469f32608b5d0c782452647fe3f246dc20e7 Mon Sep 17 00:00:00 2001 From: Matthias Held Date: Thu, 10 Dec 2020 21:34:47 +0100 Subject: check if path is empty --- lib/Monitor.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/Monitor.php b/lib/Monitor.php index b1dad47..66cb750 100644 --- a/lib/Monitor.php +++ b/lib/Monitor.php @@ -136,6 +136,11 @@ class Monitor public function analyze($paths, $mode) { $path = $paths[0]; + + if ($path === '') { + $this->logger->debug("Path is empty."); + return; + } $storage = $this->rootFolder->getUserFolder($this->userId)->get(dirname($path))->getStorage(); if ($this->userId === null || $this->nestingLevel !== 0 || /*!$this->isUploadedFile($storage, $path) ||*/ $this->isCreatingSkeletonFiles()) { @@ -216,7 +221,7 @@ class Monitor return; case self::DELETE: - $this->logger->debug("Delete", ['app' => Application::APP_ID]); + $this->logger->debug("Delete ".$path, ['app' => Application::APP_ID]); // reset PROPFIND_COUNT $this->resetProfindCount(); @@ -242,7 +247,7 @@ class Monitor return; case self::CREATE: - $this->logger->debug("Create", ['app' => Application::APP_ID]); + $this->logger->debug("Create ".$path, ['app' => Application::APP_ID]); // reset PROPFIND_COUNT $this->resetProfindCount(); -- cgit v1.2.3