diff options
author | Raphael <raphael@joindiaspora.com> | 2010-08-02 21:05:34 +0400 |
---|---|---|
committer | Raphael <raphael@joindiaspora.com> | 2010-08-02 21:05:34 +0400 |
commit | b8ae6b44a2bd44abad8b7b04c1c4584a16dba679 (patch) | |
tree | 54c15008a74b302250b64441005e39cea7c62d64 /app/uploaders | |
parent | dc1a164b67cae7c820be75cb2dff454d0348fd45 (diff) |
RS; Image filename is now the Photo model id
Diffstat (limited to 'app/uploaders')
-rw-r--r-- | app/uploaders/image_uploader.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/uploaders/image_uploader.rb b/app/uploaders/image_uploader.rb index 7bf9cf2fe..af157647d 100644 --- a/app/uploaders/image_uploader.rb +++ b/app/uploaders/image_uploader.rb @@ -10,7 +10,11 @@ class ImageUploader < CarrierWave::Uploader::Base def extension_white_list %w(jpg jpeg gif png) end - + + def filename + model.id.to_s + File.extname(@filename) + end + version :thumb_small do process :resize_to_fill => [30,30] end |