From f1a31c7f6b6c9763a9cbbc489e491e893a54fea0 Mon Sep 17 00:00:00 2001 From: yanxd Date: Sat, 12 Oct 2013 10:36:50 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E5=8D=87=E5=A4=B4=E5=83=8F=E5=9B=BE?= =?UTF-8?q?=E7=89=87=E6=98=BE=E7=A4=BA=E5=88=86=E8=BE=A8=E5=8A=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/avatar_controller.rb | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/app/controllers/avatar_controller.rb b/app/controllers/avatar_controller.rb index 7497e4573..90d5b0837 100644 --- a/app/controllers/avatar_controller.rb +++ b/app/controllers/avatar_controller.rb @@ -54,10 +54,12 @@ class AvatarController < ApplicationController # @avatar.image_file = params[:filename].presence || Redmine::Utils.random_hex(16) # saved = @avatar.save begin - f= Magick::ImageList.new(diskfile) - f.scale!(50,50) - f.write(diskfile) - rescue + f = Magick::ImageList.new(diskfile) + f.scale!(100,100) + #f.scale!(50,50) + f.write(diskfile) + rescue Exception => e + logger.error "[avatar] Error : avatar_cntroller#upload ===> #{e}" end