summaryrefslogtreecommitdiff
path: root/platform/javascript
diff options
context:
space:
mode:
authorLuis Sanchez <fro-z@email.cz>2021-12-03 17:45:45 +0100
committerLuis Sanchez <fro-z@email.cz>2021-12-03 20:21:39 +0100
commit40f26cb26097ab7ad62b18ec6018221616124b3f (patch)
treebe2e752bee992b96e80406919c40095dafbcbb01 /platform/javascript
parent0e261523926e776bc0b1b85178a60fa476490a9c (diff)
Fix files_dropped in HTML5 export.
(Ignore trailing slash when creating the temporary directory)
Diffstat (limited to 'platform/javascript')
-rw-r--r--platform/javascript/js/libs/library_godot_input.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/javascript/js/libs/library_godot_input.js b/platform/javascript/js/libs/library_godot_input.js
index 945dbba902..f403e85a30 100644
--- a/platform/javascript/js/libs/library_godot_input.js
+++ b/platform/javascript/js/libs/library_godot_input.js
@@ -262,7 +262,7 @@ const GodotInputDragDrop = {
const DROP = `/tmp/drop-${parseInt(Math.random() * (1 << 30), 10)}/`;
const drops = [];
const files = [];
- FS.mkdir(DROP);
+ FS.mkdir(DROP.slice(0, -1)); // Without trailing slash
GodotInputDragDrop.pending_files.forEach((elem) => {
const path = elem['path'];
GodotFS.copy_to_fs(DROP + path, elem['data']);