]> git.openstreetmap.org Git - rails.git/blobdiff - app/models/diary_entry.rb
Use utility method for error reporting.
[rails.git] / app / models / diary_entry.rb
index 8063372da9065c67c18c15a4f0dce2847cc39485..46d96fec7d86fbf85b85bed3b6646d5784033c9d 100644 (file)
@@ -1,7 +1,7 @@
 class DiaryEntry < ActiveRecord::Base
   belongs_to :user
   has_many :diary_comments, :include => :user,
-                            :conditions => "users.visible = 1",
+                            :conditions => ["users.visible = ?", true],
                             :order => "diary_comments.id"
 
   validates_presence_of :title, :body