From ecfa89a7f73def9b39ae6c85a4eb2e4933b299f3 Mon Sep 17 00:00:00 2001 From: imShadow Date: Wed, 15 Apr 2015 15:24:30 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=AD=98=E5=82=A8=E6=8F=92?= =?UTF-8?q?=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- content/storage/qiniu-store/index.js | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/content/storage/qiniu-store/index.js b/content/storage/qiniu-store/index.js index 745f628edd8..de1949a664b 100644 --- a/content/storage/qiniu-store/index.js +++ b/content/storage/qiniu-store/index.js @@ -45,11 +45,11 @@ QINIUStore.prototype.save = function (image) { var uptoken = putPolicy.token(); var key = options.prefix + filename; - console.log( 'QINIUStore::UPLOAD filename=', filename ); + // console.log( 'QINIUStore::UPLOAD filename=', filename ); // console.log( 'QINIUStore::image.path=', image.path ); // console.log( 'QINIUStore::qiniu.conf=', qiniu.conf ); // console.log( 'QINIUStore::uptoken=', uptoken ); - console.log( 'QINIUStore::UPLOAD key=', key ); + // console.log( 'QINIUStore::UPLOAD key=', key ); // 上传文件到云存储 qiniu.io.putFile(uptoken, key, image.path, null, function(err, ret) { @@ -64,7 +64,7 @@ QINIUStore.prototype.save = function (image) { // ret.key & ret.hash } else { // 上传失败, 处理返回代码 - // console.log('QINIUStore save ERROR:' , err ); + console.log('QINIUStore save ERROR:' , err ); return reject( err ); } }); @@ -82,8 +82,8 @@ QINIUStore.prototype.exists = function (filename ) { var key = options.prefix + filename; var client = new qiniu.rs.Client(); - console.log( 'QINIUStore::CHECK key=', key ); - console.log( 'QINIUStore::CHECK filename=', filename ); + // console.log( 'QINIUStore::CHECK key=', key ); + // console.log( 'QINIUStore::CHECK filename=', filename ); client.stat( options.bucket , key, function(err, ret) { if (!err) { @@ -118,7 +118,6 @@ QINIUStore.prototype.serve = function () { res.redirect( 301, options.protocol + '://' + options.domain + '/' + options.prefix + mountPoint + req.path ); // next(); }; - }; module.exports = QINIUStore; \ No newline at end of file