accept comments from strangers

This commit is contained in:
Raphael 2010-08-26 12:01:11 -07:00
parent c7974f8046
commit f3c20bf3c0
2 changed files with 1 additions and 3 deletions

View file

@ -58,8 +58,7 @@ class Comment
end
def signature_valid?
Rails.logger.warn "Received comment has no person" unless person
verify_signature(creator_signature, person)
person ? verify_signature(creator_signature, person) : true
end
protected

View file

@ -195,7 +195,6 @@ class User
person.save
elsif object.is_a?(Comment)
object.person.save
raise "In receive for #{self.real_name}, signature was not valid on: #{object.inspect}" unless object.post.person == self.person || object.verify_post_creator_signature
object.save
dispatch_comment object unless owns?(object)