- if node.visible
- new_node = Node.from_xml(request.raw_post)
-
- if new_node and new_node.id == node.id
- node.timestamp = Time.now
- node.user_id = @user.id
-
- node.latitude = new_node.latitude
- node.longitude = new_node.longitude
- node.tags = new_node.tags
-
- if node.save_with_history
- render :nothing => true
- else
- render :nothing => true, :status => :internal_server_error
- end
- else
- render :nothing => true, :status => :bad_request
- end
+ if new_node and new_node.id == node.id
+ node.update_from(new_node, @user)
+ render :text => node.version.to_s, :content_type => "text/plain"