mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
fix: calculate node limit using MiB instead of MB
Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
This commit is contained in:
parent
eda72da5ae
commit
05613984bb
1 changed files with 2 additions and 1 deletions
|
|
@ -98,7 +98,8 @@ class GenerateMetadataJob extends TimedJob {
|
|||
// Files are loaded in memory so very big files can lead to an OOM on the server
|
||||
$nodeSize = $node->getSize();
|
||||
$nodeLimit = $this->config->getSystemValueInt('metadata_max_filesize', self::DEFAULT_MAX_FILESIZE);
|
||||
if ($nodeSize > $nodeLimit * 1000000) {
|
||||
$nodeLimitMib = $nodeLimit * 1024 * 1024;
|
||||
if ($nodeSize > $nodeLimitMib) {
|
||||
$this->logger->debug('Skipping generating metadata for fileid ' . $node->getId() . " as its size exceeds configured 'metadata_max_filesize'.");
|
||||
continue;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue