Sha256: dfe6c34e7c01e839317ac6423349e31b9de3880efb9438e631788fa408232da1

Contents?: true

Size: 227 Bytes

Versions: 4

Compression:

Stored size: 227 Bytes

Contents

class WysihatFile < ActiveRecord::Base
  has_attached_file :file, :styles => { :medium => "300x300>", :thumb => "100x100>" }
  before_post_process :image?
  
  def image?
    !(file_content_type =~ /^image.*/).nil?
  end
  
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
bcalloway-wysihat-engine-0.1.11 app/models/wysihat_file.rb
bcalloway-wysihat-engine-0.1.10 app/models/wysihat_file.rb
bcalloway-wysihat-engine-0.1.9 app/models/wysihat_file.rb
bcalloway-wysihat-engine-0.1.8 app/models/wysihat_file.rb