Skip to content

Commit

Permalink
Use type of content type if not specified
Browse files Browse the repository at this point in the history
  • Loading branch information
kriszyp committed Jun 25, 2013
1 parent 95b3c62 commit 9e0d3d1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions media.js
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ exports.saveFile = function(file, directives){
metadata[i] = file[i];
}
}
file['content-type'] = file['content-type'] || file.type;
return when(exports.getFileModel().put(file, directives), function(result){
var id = result.id || result;
result = {id: id, getMetadata: result.getMetadata};
Expand Down

0 comments on commit 9e0d3d1

Please sign in to comment.