]> git.openstreetmap.org Git - rails.git/blobdiff - app/models/diary_entry.rb
Pass the correct locale to Nominatim.describe_location
[rails.git] / app / models / diary_entry.rb
index 64a412d28c771a55da936381c04f37737371962a..99a56b2ce1b8c4486110c4a9ba5662be171c3667 100644 (file)
@@ -1,7 +1,7 @@
 class DiaryEntry < ActiveRecord::Base
 class DiaryEntry < ActiveRecord::Base
-  belongs_to :user
+  belongs_to :user, :counter_cache => true
   belongs_to :language, :foreign_key => 'language_code'
   belongs_to :language, :foreign_key => 'language_code'
-  
+
   has_many :comments, :class_name => "DiaryComment",
                       :include => :user,
                       :order => "diary_comments.id"
   has_many :comments, :class_name => "DiaryComment",
                       :include => :user,
                       :order => "diary_comments.id"