Skip to content
This repository has been archived by the owner on Mar 25, 2019. It is now read-only.

Commit

Permalink
fix: set post filename right
Browse files Browse the repository at this point in the history
  • Loading branch information
翰文 committed Apr 7, 2015
1 parent 2fea335 commit 70c1d7a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/utils/request.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ var request = require('superagent');
exports.upload = function(file, config) {
var req = request
.post(config.action)
.attach(config.paramName, file, file.type);
.attach(config.paramName, file, file.name);
for (var key in config.data) {
req.field(key, config.data[key]);
}
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rc-dropzone",
"version": "1.0.6",
"version": "1.1.0",
"description": "dropzone ui component for react",
"keywords": [
"react",
Expand Down Expand Up @@ -50,6 +50,7 @@
"expect.js": "~0.3.1",
"file-loader": "^0.8.1",
"jsx-loader": "^0.12.2",
"phantomjs2": "^2.0.0",
"precommit-hook": "^1.0.7",
"rc-server": "^2.0.0",
"rc-tools": "^1.1.0",
Expand Down

0 comments on commit 70c1d7a

Please sign in to comment.