Skip to content

Commit d99fbef

Browse files
committed
Added additional file existence check on temporary file cleanup for dumpFile method
1 parent 17b83e3 commit d99fbef

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Filesystem.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -695,7 +695,9 @@ public function dumpFile($filename, $content)
695695

696696
$this->rename($tmpFile, $filename, true);
697697
} finally {
698-
@unlink($tmpFile);
698+
if (file_exists($tmpFile)) {
699+
@unlink($tmpFile);
700+
}
699701
}
700702
}
701703

0 commit comments

Comments
 (0)