X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/9544ab12b8237b4e471f03df981a189c80216c63..6e565802786cfed6350534c984ad20ed49348f01:/app/models/old_node.rb diff --git a/app/models/old_node.rb b/app/models/old_node.rb index 3a0ecc367..5ea3a778b 100644 --- a/app/models/old_node.rb +++ b/app/models/old_node.rb @@ -63,11 +63,6 @@ class OldNode < ActiveRecord::Base def save_with_dependencies! save! - #not sure whats going on here - clear_aggregation_cache - clear_association_cache - #ok from here - @attributes.update(OldNode.where(:node_id => self.node_id, :timestamp => self.timestamp, :version => self.version).first.instance_variable_get('@attributes')) self.tags.each do |k,v| tag = OldNodeTag.new @@ -80,14 +75,7 @@ class OldNode < ActiveRecord::Base end def tags - unless @tags - @tags = Hash.new - self.old_tags.each do |tag| - @tags[tag.k] = tag.v - end - end - @tags = Hash.new unless @tags - @tags + @tags ||= Hash[self.old_tags.collect { |t| [t.k, t.v] }] end def tags=(t)