Skip to content
This repository was archived by the owner on Jun 2, 2024. It is now read-only.

Commit e1792e7

Browse files
Only unlink existing files
1 parent c7b426a commit e1792e7

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Filesystem.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,10 @@ public static function write($path, $contents)
6666
*/
6767
public static function delete($path)
6868
{
69+
if (!file_exists($path)) {
70+
return true;
71+
}
72+
6973
return unlink($path);
7074
}
7175

0 commit comments

Comments
 (0)