From b0d884ef81fd1af324d1131f14c9ae484fe1e59d Mon Sep 17 00:00:00 2001 From: soomtong Date: Tue, 1 Jan 2013 12:46:17 +0900 Subject: [PATCH] Update lib/uploadhandler.js MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit update resize with cropping custom options : customArgs ex) thumbnail:{     width:80,     height:"80^",     customArgs: [         "-gravity", "center",         "-extent", "80x80"     ] } --- lib/uploadhandler.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/uploadhandler.js b/lib/uploadhandler.js index 7f21ffc..53439ba 100644 --- a/lib/uploadhandler.js +++ b/lib/uploadhandler.js @@ -109,7 +109,7 @@ module.exports = function (options) { height: opts.height, srcPath: options.uploadDir() + '/' + fileInfo.name, dstPath: options.uploadDir() + '/' + version + '/' + fileInfo.name, - customArgs: ['-auto-orient'] + customArgs: opts.customArgs || ['-auto-orient'] }, finish); }); }