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 5e9f91e commit fdadb93Copy full SHA for fdadb93
src/Types/TemporaryFile.php
@@ -29,12 +29,15 @@ public function __construct(
29
protected string $toFolder,
30
protected string $toDisk,
31
protected bool $keepOriginalName,
32
+ protected int $permissions = 0664,
33
) {
34
$this->tmpPath = tempnam(sys_get_temp_dir(), 'tmp');
35
36
if (file_put_contents($this->tmpPath, $content) === false) {
37
throw UploadedFileWriteException::cannotWriteTemporaryFile($this->tmpPath);
38
}
39
+
40
+ chmod($this->tmpPath, $permissions);
41
42
43
/**
0 commit comments