From: Wallace Reis Date: Mon, 11 Jun 2012 12:39:04 +0000 (+0200) Subject: Fix default OPTIONS handler X-Git-Tag: 1.03~6 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Action-REST.git;a=commitdiff_plain;h=ffcae14131f4334ab08b42e5eed0b012933f51df Fix default OPTIONS handler As the ->body is defined, then serialization won't happen and we don't wrong responses as from failing tests in prev commit. --- diff --git a/lib/Catalyst/Action/REST.pm b/lib/Catalyst/Action/REST.pm index bc715f6..9787eef 100644 --- a/lib/Catalyst/Action/REST.pm +++ b/lib/Catalyst/Action/REST.pm @@ -159,6 +159,7 @@ sub _return_options { $c->response->content_type('text/plain'); $c->response->status(200); $c->response->header( 'Allow' => \@allowed ); + $c->response->body(q{}); } sub _return_not_implemented {