summaryrefslogtreecommitdiffstats
path: root/lib/puppet/network/http/mongrel
diff options
context:
space:
mode:
authorRick Bradley <rick@rickbradley.com>2007-10-23 12:32:45 -0500
committerRick Bradley <rick@rickbradley.com>2007-10-23 12:32:45 -0500
commit54fc80d5de7b881adca06c85206fb700f4278a73 (patch)
tree20e33372f0fe2abedc2c589a4cb32de471bcf928 /lib/puppet/network/http/mongrel
parente7bfe0bf9b525d6216cbb24be99357d33c0b87ec (diff)
downloadpuppet-54fc80d5de7b881adca06c85206fb700f4278a73.tar.gz
puppet-54fc80d5de7b881adca06c85206fb700f4278a73.tar.xz
puppet-54fc80d5de7b881adca06c85206fb700f4278a73.zip
Exceptions on requests are now captured, exceptions are serialized, and exception text is passed back via REST.
Diffstat (limited to 'lib/puppet/network/http/mongrel')
-rw-r--r--lib/puppet/network/http/mongrel/rest.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/puppet/network/http/mongrel/rest.rb b/lib/puppet/network/http/mongrel/rest.rb
index f22b4c4c9..db63613ab 100644
--- a/lib/puppet/network/http/mongrel/rest.rb
+++ b/lib/puppet/network/http/mongrel/rest.rb
@@ -29,8 +29,8 @@ class Puppet::Network::HTTP::MongrelREST < Puppet::Network::HTTP::Handler
Mongrel::HttpRequest.query_parse(request.params["QUERY_STRING"])
end
- def encode_result(request, response, result)
- response.start(200) do |head, body|
+ def encode_result(request, response, result, status = 200)
+ response.start(status) do |head, body|
body.write(result)
end
end