diff --git a/lib/Controller/WopiController.php b/lib/Controller/WopiController.php index e7121264f2..00bc1d3e23 100644 --- a/lib/Controller/WopiController.php +++ b/lib/Controller/WopiController.php @@ -493,7 +493,7 @@ public function putFile($fileId, $content = fopen('php://input', 'rb'); - $freespace = $file->getParent()->getFreeSpace(); + $freespace = (int)$file->getStorage()->free_space($file->getInternalPath()); $contentLength = (int)$this->request->getHeader('Content-Length'); try {