- # We assume that an exception has been thrown if there was an error
- # generating the relation
- # if relation
- relation.create_with_history @user
- render :text => relation.id.to_s, :content_type => "text/plain"
- # else
- # render :text => "Couldn't get turn the input into a relation.", :status => :bad_request
- # end
+ # Assume that Relation.from_xml has thrown an exception if there is an error parsing the xml
+ relation.create_with_history current_user
+ render :plain => relation.id.to_s