If the parent is not cached we should request the file

Else we ignore all incomming shares. Which basically does 💥

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
Roeland Jago Douma 2018-12-06 21:59:28 +01:00 committed by Backportbot
parent edab262b0e
commit 4ed291ce23
1 changed files with 3 additions and 3 deletions

View File

@ -112,11 +112,11 @@ class CommentPropertiesPlugin extends ServerPlugin {
if ($parentPath === '') { if ($parentPath === '') {
$parentPath = '/'; $parentPath = '/';
} }
// if we already cached the folder this file is in we know there are no shares for this file // if we already cached the folder this file is in we know there are no comments for this file
if (array_search($parentPath, $this->cachedFolders) === false) { if (array_search($parentPath, $this->cachedFolders) === false) {
return $this->getUnreadCount($node);
} else {
return 0; return 0;
} else {
return $this->getUnreadCount($node);
} }
} }
}); });