Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2019-03-21 00:30:38 +0300
committerGitHub <noreply@github.com>2019-03-21 00:30:38 +0300
commita5cbe94878b4dbaa4c00ad1babd326ef0f347708 (patch)
treed5abf918632f92752d3a4df6a88776e54e17f0fb
parent6fffd09a7ce7d7df4c98da474624e513cc88691f (diff)
parentfad5424165a5015bab6611f11185190ce9500de0 (diff)
Merge pull request #14762 from nextcloud/backport/14674/stable15
[stable15] [app:files] Use current directory for hashing.
-rw-r--r--apps/files/js/file-upload.js7
1 files changed, 3 insertions, 4 deletions
diff --git a/apps/files/js/file-upload.js b/apps/files/js/file-upload.js
index 827f1317fb3..47d22447c91 100644
--- a/apps/files/js/file-upload.js
+++ b/apps/files/js/file-upload.js
@@ -34,12 +34,11 @@
OC.FileUpload = function(uploader, data) {
this.uploader = uploader;
this.data = data;
- var path = '';
+ var basePath = '';
if (this.uploader.fileList) {
- path = OC.joinPaths(this.uploader.fileList.getCurrentDirectory(), this.getFile().name);
- } else {
- path = this.getFile().name;
+ basePath = this.uploader.fileList.getCurrentDirectory();
}
+ var path = OC.joinPaths(basePath, this.getFile().relativePath || '', this.getFile().name);
this.id = 'web-file-upload-' + md5(path) + '-' + (new Date()).getTime();
};
OC.FileUpload.CONFLICT_MODE_DETECT = 0;