From: Thomas Wood Date: Thu, 30 Apr 2009 07:10:57 +0000 (+0000) Subject: Fix another error reporting bug similar to previous, again on printing RelationMember... X-Git-Tag: live~8010 X-Git-Url: https://git.openstreetmap.org./rails.git/commitdiff_plain/2861236f602b3686deb62add6de0565ba8108fee?hp=bb3108cb99e95775492157fe135eeda5e70a664e Fix another error reporting bug similar to previous, again on printing RelationMember.id rather than RelationMember.relation.id --- diff --git a/app/models/node.rb b/app/models/node.rb index 035a07eac..987df9b13 100644 --- a/app/models/node.rb +++ b/app/models/node.rb @@ -137,7 +137,7 @@ class Node < ActiveRecord::Base rel = RelationMember.find(:first, :joins => "INNER JOIN current_relations ON current_relations.id=current_relation_members.id", :conditions => [ "visible = ? AND member_type='Node' and member_id=? ", true, self.id]) - raise OSM::APIPreconditionFailedError.new("Node #{self.id} is still used by relation #{rel.id}.") unless rel.nil? + raise OSM::APIPreconditionFailedError.new("Node #{self.id} is still used by relation #{rel.relation.id}.") unless rel.nil? self.changeset_id = new_node.changeset_id self.visible = false