Commit f1acdf0f

mo khan <mo@mokhan.ca>
2013-12-28 14:19:34
downcase the creation name for urls.
1 parent 56fb44e
Changed files (1)
app
app/models/creation.rb
@@ -9,7 +9,7 @@ class Creation < ActiveRecord::Base
   default_scope -> { order(:created_at => :desc) }
 
   def to_param
-    "#{id}-#{name.gsub(/[^a-z0-9]+/i, '-')}"
+    "#{id}-#{name.downcase.gsub(/[^a-z0-9]+/i, '-')}"
   end
 
   def primary_image