app/models/gallery/photo.rb in comfy_gallery-0.1.0 vs app/models/gallery/photo.rb in comfy_gallery-0.1.1
- old
+ new
@@ -28,13 +28,9 @@
after_update :reprocess_image, :if => :cropping?
# -- Validations ----------------------------------------------------------
validates :gallery_id,
:presence => true
- validates :slug,
- :presence => true,
- :uniqueness => true,
- :format => { :with => /^\w[a-z0-9_-]*$/i }
validates_attachment_presence :image,
:message => 'There was no file uploaded!'
validates_attachment_content_type :image,
:content_type => %w(image/jpeg image/pjpeg image/gif image/png image/x-png),
:message => 'Please only upload .jpg, .jpeg, .gif or .png files.'
\ No newline at end of file