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 42a7645 commit ed1e991Copy full SHA for ed1e991
Filesystem.php
@@ -100,12 +100,9 @@ public function exists($files)
100
*/
101
public function touch($files, $time = null, $atime = null)
102
{
103
- if (null === $time) {
104
- $time = time();
105
- }
106
-
107
foreach ($this->toIterator($files) as $file) {
108
- if (true !== @touch($file, $time, $atime)) {
+ $touch = $time ? @touch($file, $time, $atime) : @touch($file);
+ if (true !== $touch) {
109
throw new IOException(sprintf('Failed to touch %s', $file));
110
}
111
0 commit comments