ncp-web: fix upload from local file path

Signed-off-by: nachoparker <nacho@ownyourbits.com>
This commit is contained in:
nachoparker 2021-09-30 22:48:27 -06:00
parent 26edf1f7b0
commit 05f0d352cf
2 changed files with 2 additions and 2 deletions

View File

@ -1,5 +1,5 @@
[v1.39.19](https://github.com/nextcloud/nextcloudpi/commit/b177bd1) (2021-09-30) ncp-web: fix upload from local file path
[v1.39.19](https://github.com/nextcloud/nextcloudpi/commit/92bec43) (2021-09-30) ncp-web: fix upload from local file path
[v1.39.18](https://github.com/nextcloud/nextcloudpi/commit/f1c90f5) (2021-09-30) nc-httpsonly: always use overwriteprotocol https in all cases

View File

@ -38,7 +38,7 @@ $extension = pathinfo($file_name, PATHINFO_EXTENSION);
if ($extension !== "tar" and $extension !== "gz")
exit( '{ "output": "invalid file" }' );
if (!move_uploaded_file($file_tmp, sys_get_temp_dir() . '/' . $file_name))
if (!move_uploaded_file($file_tmp, '/tmp/' . $file_name))
exit('{ "output": "upload denied" }');
// return JSON