We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5a55360 commit b3e9cdbCopy full SHA for b3e9cdb
Filesystem.php
@@ -199,7 +199,7 @@ private static function doRemove(array $files, bool $isRecursive): void
199
200
throw new IOException(sprintf('Failed to remove directory "%s": ', $file).$lastError);
201
}
202
- } elseif (!self::box('unlink', $file) && (str_contains(self::$lastError, 'Permission denied') || file_exists($file))) {
+ } elseif (!self::box('unlink', $file) && ((self::$lastError && str_contains(self::$lastError, 'Permission denied')) || file_exists($file))) {
203
throw new IOException(sprintf('Failed to remove file "%s": ', $file).self::$lastError);
204
205
0 commit comments