Update api_documents.class.php
This commit is contained in:
parent
4d42279fcd
commit
06979fa016
@ -756,9 +756,9 @@ class Documents extends DolibarrApi
|
|||||||
throw new RestException(500, "File with name '".$original_file."' already exists.");
|
throw new RestException(500, "File with name '".$original_file."' already exists.");
|
||||||
}
|
}
|
||||||
|
|
||||||
// in case temporary directory doesn't exist
|
// in case temporary directory admin/temp doesn't exist
|
||||||
if (!dol_is_dir(dirname(DOL_DATA_ROOT . '/admin/temp/'))) {
|
if (!dol_is_dir(dirname($destfiletmp))) {
|
||||||
dol_mkdir(DOL_DATA_ROOT . '/admin/temp/');
|
dol_mkdir(dirname($destfiletmp));
|
||||||
}
|
}
|
||||||
|
|
||||||
$fhandle = @fopen($destfiletmp, 'w');
|
$fhandle = @fopen($destfiletmp, 'w');
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user