aboutsummaryrefslogtreecommitdiffhomepage
path: root/cli
diff options
context:
space:
mode:
Diffstat (limited to 'cli')
-rw-r--r--cli/actions.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/cli/actions.js b/cli/actions.js
index 69ffa10..ea2a3a1 100644
--- a/cli/actions.js
+++ b/cli/actions.js
@@ -118,7 +118,7 @@ function put(filePath, otherFilePaths, options) {
118 var destinationPath = (destination ? '/' + destination : '') + '/' + relativeFilePath; 118 var destinationPath = (destination ? '/' + destination : '') + '/' + relativeFilePath;
119 console.log('Uploading file %s -> %s', relativeFilePath.cyan, destinationPath.cyan); 119 console.log('Uploading file %s -> %s', relativeFilePath.cyan, destinationPath.cyan);
120 120
121 superagent.put(config.server() + API + destinationPath).query(gQuery).attach('file', file).end(function (error, result) { 121 superagent.post(config.server() + API + destinationPath).query(gQuery).attach('file', file).end(function (error, result) {
122 if (result && result.statusCode === 403) return callback(new Error('Upload destination ' + destinationPath + ' not allowed')); 122 if (result && result.statusCode === 403) return callback(new Error('Upload destination ' + destinationPath + ' not allowed'));
123 if (result && result.statusCode !== 201) return callback(new Error('Error uploading file: ' + result.statusCode)); 123 if (result && result.statusCode !== 201) return callback(new Error('Error uploading file: ' + result.statusCode));
124 if (error) return callback(error); 124 if (error) return callback(error);