Transmit OC-Total-Length in browser as well

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
This commit is contained in:
Thomas Müller 2017-08-10 12:23:20 +02:00 committed by Daniel Calviño Sánchez
parent 74df27b7a7
commit f39de4ab37
1 changed files with 4 additions and 1 deletions

View File

@ -264,7 +264,10 @@ OC.FileUpload.prototype = {
'uploads/' + encodeURIComponent(uid) + '/' + encodeURIComponent(this.getId()) + '/.file', 'uploads/' + encodeURIComponent(uid) + '/' + encodeURIComponent(this.getId()) + '/.file',
'files/' + encodeURIComponent(uid) + '/' + OC.joinPaths(this.getFullPath(), this.getFileName()), 'files/' + encodeURIComponent(uid) + '/' + OC.joinPaths(this.getFullPath(), this.getFileName()),
true, true,
{'X-OC-Mtime': this.getFile().lastModified / 1000} {
'X-OC-Mtime': this.getFile().lastModified / 1000,
'OC-Total-Length': this.getFile().size
}
); );
}, },