From: Richard Fairhurst Date: Sun, 5 Oct 2008 00:21:35 +0000 (+0000) Subject: Potlatch 0.10d X-Git-Tag: live~7657 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/97726826e1bcdec2369996aa0b1b0db737a58926?hp=98ed7a815cd1e81a9955d771154257432f7cfd4a Potlatch 0.10d --- diff --git a/app/controllers/amf_controller.rb b/app/controllers/amf_controller.rb index 51e49849f..70f8f427d 100644 --- a/app/controllers/amf_controller.rb +++ b/app/controllers/amf_controller.rb @@ -159,7 +159,9 @@ class AmfController < ApplicationController # way includes a node more than once way = Way.find(wayid) points = way.nodes.collect do |node| - [node.lon, node.lat, node.id, nil, node.tags_as_hash] + nodetags=node.tags_as_hash + nodetags.delete('created_by') + [node.lon, node.lat, node.id, nodetags] end tags = way.tags end @@ -352,8 +354,10 @@ class AmfController < ApplicationController savenode = true else node = Node.find(id) + nodetags=node.tags_as_hash + nodetags.delete('created_by') if !fpcomp(lat, node.lat) or !fpcomp(lon, node.lon) or - Tags.join(n[4]) != node.tags or !node.visible? + n[4] != nodetags or !node.visible? savenode = true end end @@ -582,7 +586,9 @@ class AmfController < ApplicationController ORDER BY sequence_id EOF ActiveRecord::Base.connection.select_all(sql).each do |row| - points << [row['lon'].to_f,row['lat'].to_f,row['id'].to_i,nil,tagstring_to_hash(row['tags'])] + nodetags=tagstring_to_hash(row['tags']) + nodetags.delete('created_by') + points << [row['lon'].to_f,row['lat'].to_f,row['id'].to_i,nodetags] end points end diff --git a/app/views/site/edit.rhtml b/app/views/site/edit.rhtml index 7f542bb60..9c3c78fda 100644 --- a/app/views/site/edit.rhtml +++ b/app/views/site/edit.rhtml @@ -48,7 +48,7 @@ <%= javascript_include_tag 'swfobject.js' %>