[Catalyst] Catalyst::Plugin::DefaultEnd - returning a false string (zeroes)

Carl Franks fireartist at gmail.com
Fri Apr 7 15:30:34 CEST 2006


On 07/04/06, ADSJ (Adam Sjøgren) <adsj at novozymes.com> wrote:

> -    return 1 if $c->response->body;
> +    return 1 if length $c->response->body;

That'll cause a warning whenever body is undefined.

It should probably be:

return 1 if defined $c->response->body && length $c->response->body;

Cheers,
Carl



More information about the Catalyst mailing list