Handle possible null value for file in OC\Files\SimpleFS\NewSimpleFile

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
pull/35576/head
Thomas Citharel 3 years ago
parent 299f979d94
commit a5b6119ec4
No known key found for this signature in database
GPG Key ID: A061B9DDE0CA0773
  1. 4
      lib/private/Files/SimpleFS/NewSimpleFile.php

@ -136,6 +136,10 @@ class NewSimpleFile implements ISimpleFile {
* @throws NotFoundException
*/
private function checkFile(): void {
if (!$this->file) {
throw new NotFoundException('File not set');
}
$cur = $this->file;
while ($cur->stat() === false) {

Loading…
Cancel
Save