]> git.openstreetmap.org Git - rails.git/commitdiff
Convert XML document to a string when returning it
authorTom Hughes <tom@compton.nu>
Tue, 13 Jun 2017 11:55:13 +0000 (12:55 +0100)
committerTom Hughes <tom@compton.nu>
Tue, 13 Jun 2017 11:55:13 +0000 (12:55 +0100)
Otherwise the Rak::ETag module will throw an exception when it
tries to test if the response is empty.

app/controllers/changeset_controller.rb

index 9aaf6c7e01a78dbdeb47ed46573033213a6c40c4..e80eb16105e2b0938462b060b934e5cb9d46ef53 100644 (file)
@@ -244,7 +244,7 @@ class ChangesetController < ApplicationController
 
     check_changeset_consistency(changeset, @user)
     changeset.update_from(new_changeset, @user)
 
     check_changeset_consistency(changeset, @user)
     changeset.update_from(new_changeset, @user)
-    render :xml => changeset.to_xml
+    render :xml => changeset.to_xml.to_s
   end
 
   ##
   end
 
   ##