swap way write with node deletion as per dev@
This commit is contained in:
parent
418963da42
commit
c9237a3583
1 changed files with 8 additions and 8 deletions
|
@ -397,6 +397,14 @@ class AmfController < ApplicationController
|
||||||
nodes.push(id)
|
nodes.push(id)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# -- Save revised way
|
||||||
|
|
||||||
|
way.tags = attributes
|
||||||
|
way.nds = nodes
|
||||||
|
way.user_id = uid
|
||||||
|
way.visible = true
|
||||||
|
way.save_with_history!
|
||||||
|
|
||||||
# -- Delete any unique nodes
|
# -- Delete any unique nodes
|
||||||
|
|
||||||
uniques.each do |n|
|
uniques.each do |n|
|
||||||
|
@ -408,14 +416,6 @@ class AmfController < ApplicationController
|
||||||
node.save_with_history!
|
node.save_with_history!
|
||||||
end
|
end
|
||||||
|
|
||||||
# -- Save revised way
|
|
||||||
|
|
||||||
way.tags = attributes
|
|
||||||
way.nds = nodes
|
|
||||||
way.user_id = uid
|
|
||||||
way.visible = true
|
|
||||||
way.save_with_history!
|
|
||||||
|
|
||||||
[0, originalway, way.id, renumberednodes]
|
[0, originalway, way.id, renumberednodes]
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue