mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 13:12:50 +01:00
Merge pull request #4875 from turbo124/v5-develop
Fixes for attachments
This commit is contained in:
commit
51fdd4a985
@ -25,7 +25,11 @@ class TempFile
|
||||
public static function filePath($data, $filename) :string
|
||||
{
|
||||
|
||||
$file_path = sys_get_temp_dir().'/'.sha1(microtime() . '/' . $filename);
|
||||
$dir_hash = sys_get_temp_dir().'/'.sha1(microtime());
|
||||
|
||||
mkdir($dir_hash);
|
||||
|
||||
$file_path = $dir_hash . '/' . $filename;
|
||||
|
||||
file_put_contents($file_path, $data);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user