aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobin Appelman <robin@icewind.nl>2024-11-14 15:18:06 +0100
committerRobin Appelman <robin@icewind.nl>2024-11-14 15:18:06 +0100
commitf5c9d3e6fdf36d3cd47243b470ed4ed767fe5dbd (patch)
tree5f6e217dde958297be8b1bc003529b75e57eacc1
parent22e2419b2828c5866a32c9da43cbaa8c8a2898ea (diff)
downloadnextcloud-server-scanner-invalid-data-log.tar.gz
nextcloud-server-scanner-invalid-data-log.zip
debug: log invalid data being used in scannerscanner-invalid-data-log
Signed-off-by: Robin Appelman <robin@icewind.nl>
-rw-r--r--lib/private/Files/Cache/Scanner.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/private/Files/Cache/Scanner.php b/lib/private/Files/Cache/Scanner.php
index 3bd674f79e2..591526492de 100644
--- a/lib/private/Files/Cache/Scanner.php
+++ b/lib/private/Files/Cache/Scanner.php
@@ -133,6 +133,10 @@ class Scanner extends BasicEmitter implements IScanner {
try {
$data = $data ?? $this->getData($file);
+ if (!isset($data['mimetype'])) {
+ $logger = \OC::$server->get(LoggerInterface::class);
+ $logger->error("invalid data in scanner. path: $file, storage: " . $this->storage->getId() . ', data: ' . json_encode($data));
+ }
} catch (ForbiddenException $e) {
if ($lock) {
if ($this->storage->instanceOfStorage(ILockingStorage::class)) {