line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package App::AutoCRUD::View::Redirect; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
421
|
use 5.010; |
|
1
|
|
|
|
|
3
|
|
4
|
1
|
|
|
1
|
|
3
|
use strict; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
21
|
|
5
|
1
|
|
|
1
|
|
3
|
use warnings; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
22
|
|
6
|
|
|
|
|
|
|
|
7
|
1
|
|
|
1
|
|
3
|
use Moose; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
7
|
|
8
|
|
|
|
|
|
|
extends 'App::AutoCRUD::View'; |
9
|
1
|
|
|
1
|
|
4345
|
use App::AutoCRUD::View::TT; # for its utf8_url() filter |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
27
|
|
10
|
|
|
|
|
|
|
|
11
|
1
|
|
|
1
|
|
4
|
use namespace::clean -except => 'meta'; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
7
|
|
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
sub render { |
15
|
2
|
|
|
2
|
0
|
3
|
my ($self, $url, $context) = @_; |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
# make sure the URL is url-encoded with utf8 chars |
18
|
2
|
|
|
|
|
9
|
$url = App::AutoCRUD::View::TT::utf8_url($url); |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
# SEE_OTHER http code (cf http://en.wikipedia.org/wiki/303_See_Other) |
21
|
2
|
|
|
|
|
490
|
return [303, [Location => $url], []]; |
22
|
|
|
|
|
|
|
} |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
1; |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
__END__ |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
|