diff options
author | Rémy Coutable <remy@rymai.me> | 2016-03-15 15:20:54 +0300 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2016-03-15 16:55:40 +0300 |
commit | 1714883107b7b8b8f2ef8c2836acc2866362738e (patch) | |
tree | 4c79d81c52b932c20d0ddfb467175f39e281faf3 /app/uploaders | |
parent | ea7d062fa60e3e622288237fc66a815348bbcf36 (diff) |
Revert "Merge branch 'avatar-cropping' into 'master'
"
This reverts commit 01160fc06182de89c400af174861f6545ad6ceb8, reversing
changes made to 4bff9daf8b6d85e9c78565e21cfaa3f6d36f0282.
Diffstat (limited to 'app/uploaders')
-rw-r--r-- | app/uploaders/avatar_uploader.rb | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/app/uploaders/avatar_uploader.rb b/app/uploaders/avatar_uploader.rb index 2c72df44ff0..6135c3ad96f 100644 --- a/app/uploaders/avatar_uploader.rb +++ b/app/uploaders/avatar_uploader.rb @@ -2,22 +2,11 @@ class AvatarUploader < CarrierWave::Uploader::Base include UploaderHelper - include CarrierWave::MiniMagick storage :file after :store, :reset_events_cache - process :cropper - - def cropper - return unless model.respond_to?(:avatar_crop_size) && model.valid? - - manipulate! do |img| - img.crop "#{model.avatar_crop_size}x#{model.avatar_crop_size}+#{model.avatar_crop_x}+#{model.avatar_crop_y}" - end - end - def store_dir "uploads/#{model.class.to_s.underscore}/#{mounted_as}/#{model.id}" end |