def self.from_xml(xml, create=false)
begin
- p = XML::Parser.new
- p.string = xml
+ p = XML::Parser.string(xml)
doc = p.parse
way = Way.new
# delete a way and it's nodes that aren't part of other ways, with history
def delete_with_relations_and_nodes_and_history(user)
- node_ids_to_delete = node_ids - node_ids_not_to_delete
-
# delete the nodes not used by other ways
self.unshared_node_ids.each do |node_id|
n = Node.find(node_id)