9 Apr
2010
9 Apr
'10
2:04 p.m.
Hello, Sometimes I need to redirect to another page after testing things, and I want to leave the route ASAP, so I do something like: get '/test' => sub { if(params->{whatever}) { redirect '/'; return; } "Other stuff, blah"; }; get '/' => sub { template 'index'; }; I've switched to the dev branch, and that return after the redirect results in following error: Use of uninitialized value $line in length at ../local/HTTP/Server/Simple/PSGI.pm line 137. My question is: am I doing it right using return to leave the handler? Cheers, Juanjo -- jjm's home: http://www.usebox.net/jjm/ blackshell: http://blackshell.usebox.net/ ramble on: http://rambleon.usebox.net/