Skip to content

Commit

Permalink
Merge pull request #70 from Hackwar/3.x-chmod
Browse files Browse the repository at this point in the history
Remove check for chmod in File::delete()
  • Loading branch information
richard67 authored Sep 12, 2024
2 parents c636a13 + f130533 commit c69358f
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions src/File.php
Original file line number Diff line number Diff line change
Expand Up @@ -159,10 +159,6 @@ public static function delete($file)
$file = Path::clean($file);
$filename = basename($file);

if (!Path::canChmod($file)) {
throw new FilesystemException(__METHOD__ . ': Failed deleting inaccessible file ' . $filename);
}

// Try making the file writable first. If it's read-only, it can't be deleted
// on Windows, even if the parent folder is writable
@chmod($file, 0777);
Expand Down

0 comments on commit c69358f

Please sign in to comment.