Skip to content

Commit

Permalink
Merge pull request #7656 from ccfang/fix-avatar-upload-error-cordova
Browse files Browse the repository at this point in the history
[FIX] Fix avatar upload fail on Cordova app
  • Loading branch information
rodrigok authored Aug 8, 2017
2 parents 8f3dc95 + 8c0e0d8 commit c56f09b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/rocketchat-ui-account/client/avatar/prompt.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@ Template.avatarPrompt.events({
files = event.dataTransfer && event.dataTransfer.files || [];
}

for (const file of files) {
for (let i = 0; i < files.length; i++) {
const file = files[i];
Object.defineProperty(file, 'type', { value: mime.lookup(file.name) });
}

Expand Down

0 comments on commit c56f09b

Please sign in to comment.