]> git.openstreetmap.org Git - rails.git/blobdiff - app/models/note.rb
Remove the author_name field from notes
[rails.git] / app / models / note.rb
index c32b1679b07b593f1dab2c8e9045e48cb1796e71..14806be266dfd1114e62ad324a97708aafc8e65b 100644 (file)
@@ -39,7 +39,7 @@ class Note < ActiveRecord::Base
       resp += (comment_no == 1 ? "" : separator_char)
       resp += comment.body if comment.body
       resp += " [ " 
-      resp += comment.author_name if comment.author_name
+      resp += comment.author.display_name if comment.author
       resp += " " + comment.created_at.to_s + " ]"
       comment_no += 1
     end
@@ -62,16 +62,6 @@ class Note < ActiveRecord::Base
     self.comments.first.author_ip
   end
 
-  # Return the author id, derived from the first comment
-  def author_id
-    self.comments.first.author_id
-  end
-
-  # Return the author name, derived from the first comment
-  def author_name
-    self.comments.first.author_name
-  end
-
 private
 
   # Fill in default values for new notes