diff options
author | Lukas Reschke <lukas@statuscode.ch> | 2016-12-19 14:34:56 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-12-19 14:34:56 +0100 |
commit | 34fb313466b7d3c5be8b5c7d6846bfb4e6508013 (patch) | |
tree | 4f1c769e35f1f0fa9239093817132c14052256a5 /apps | |
parent | 9b71ee27ff95336c36d608217d9621110e6674c1 (diff) | |
parent | c7fc010215f22aaff9380cb308f4794d7e2bba99 (diff) | |
download | nextcloud-server-34fb313466b7d3c5be8b5c7d6846bfb4e6508013.tar.gz nextcloud-server-34fb313466b7d3c5be8b5c7d6846bfb4e6508013.zip |
Merge pull request #2689 from andreas-p/fix-remote-conflict
Fix showConflict
Diffstat (limited to 'apps')
-rw-r--r-- | apps/files/js/file-upload.js | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/apps/files/js/file-upload.js b/apps/files/js/file-upload.js index b3a59b54241..25136d042a9 100644 --- a/apps/files/js/file-upload.js +++ b/apps/files/js/file-upload.js @@ -130,6 +130,16 @@ OC.FileUpload.prototype = { }, /** + * Get full path for the target file, + * including relative path and file name. + * + * @return {String} full path + */ + getFullFilePath: function() { + return OC.joinPaths(this.getFullPath(), this.getFile().name); + }, + + /** * Returns conflict resolution mode. * * @return {int} conflict mode @@ -508,9 +518,10 @@ OC.Uploader.prototype = _.extend({ return; } // retrieve more info about this file - this.filesClient.getFileInfo(fileUpload.getFullPath()).then(function(status, fileInfo) { + this.filesClient.getFileInfo(fileUpload.getFullFilePath()).then(function(status, fileInfo) { var original = fileInfo; var replacement = file; + original.directory = original.path; OC.dialogs.fileexists(fileUpload, original, replacement, self); }); }, |