line |
true |
false |
branch |
43
|
75 |
0 |
unless exists $conf->{'date'}
|
44
|
75 |
0 |
unless exists $conf->{'time'}
|
45
|
74 |
1 |
unless exists $conf->{'datetime'}
|
60
|
0 |
75 |
'version'->new($Mojolicious::VERSION) < 'version'->new(4.42) ? :
|
65
|
2026 |
1 |
if @_ > 2
|
72
|
1126 |
1 |
if @_ > 2
|
79
|
6 |
1 |
if @_ > 2
|
89
|
391 |
185 |
if (@_ <= 2) { }
|
|
5 |
180 |
elsif (@_ == 3) { }
|
90
|
249 |
142 |
unless exists $errors->{$name}
|
94
|
5 |
137 |
'ARRAY' eq ref $errors->{$name} ? :
|
97
|
0 |
5 |
unless exists $errors->{$name}
|
101
|
5 |
0 |
'ARRAY' eq ref $errors->{$name} ? :
|
107
|
13 |
167 |
if ($attr{'array'}) { }
|
108
|
12 |
1 |
unless exists $errors->{$name}
|
114
|
180 |
0 |
if ($conf->{'mojo_validator'})
|
125
|
3 |
3 |
unless $self->verror($name)
|
129
|
3 |
0 |
if defined $conf->{'class'} and length $conf->{'class'}
|
141
|
3 |
3 |
if (not @input) { }
|
|
1 |
2 |
elsif (@input > 1) { }
|
156
|
8 |
12 |
wantarray ? :
|
170
|
1 |
474 |
exists $params{'-optional'} ? :
|
174
|
0 |
475 |
exists $params{'-skipundef'} ? :
|
178
|
0 |
475 |
exists $params{'-multiline'} ? :
|
182
|
0 |
475 |
exists $params{'-blessed'} ? :
|
193
|
238 |
310 |
if ('HASH' eq ref $def) { }
|
|
3 |
307 |
elsif ('Regexp' eq ref $def) { }
|
|
3 |
304 |
elsif ('CODE' eq ref $def) { }
|
|
3 |
301 |
elsif ('ARRAY' eq ref $def) { }
|
|
301 |
0 |
elsif (not ref $def) { }
|
206
|
5 |
543 |
if (exists $attr{'skip'})
|
207
|
1 |
4 |
if ('CODE' eq ref $attr{'skip'}) { }
|
|
4 |
0 |
elsif ($attr{'skip'}) { }
|
209
|
1 |
0 |
if $attr{'skip'}->($self, $name)
|
224
|
530 |
13 |
if (defined $type)
|
227
|
0 |
50 |
unless $inner
|
230
|
17 |
33 |
if ($mod eq '?' or $mod =~ /^optional\[/i) { }
|
|
6 |
27 |
elsif ($mod eq '!' or $mod =~ /^required?\[/i) { }
|
|
22 |
5 |
elsif ($mod eq '@' or $mod =~ /^array\[/i) { }
|
|
2 |
3 |
elsif ($mod eq '%') { }
|
|
0 |
3 |
elsif ($mod =~ /^skipundef\[/i) { }
|
|
2 |
1 |
elsif ($mod eq '~') { }
|
246
|
528 |
2 |
if (exists $conf->{'types'}{$type}) { }
|
248
|
10 |
1458 |
if defined $attr{$key}
|
257
|
98 |
443 |
if (my $load = $attr{'load'})
|
258
|
1 |
97 |
if ('CODE' eq ref $load) { }
|
|
54 |
43 |
elsif ('ARRAY' eq ref $load) { }
|
263
|
0 |
108 |
if $e
|
267
|
0 |
43 |
if $e
|
273
|
12 |
529 |
if ($attr{'jpath?'}) { }
|
|
20 |
509 |
elsif ($attr{'jpath'}) { }
|
|
6 |
503 |
elsif ($attr{'cpath'}) { }
|
|
5 |
498 |
elsif ($attr{'xpath'}) { }
|
275
|
8 |
4 |
unless (exists $vars->{'json'})
|
281
|
6 |
6 |
if ($vars->{'json'}) { }
|
284
|
4 |
2 |
if ($vars->{'pointer'}->contains($attr{'jpath?'}))
|
286
|
0 |
4 |
'ARRAY' eq ref $value ? :
|
294
|
9 |
11 |
unless (exists $vars->{'json'})
|
300
|
18 |
2 |
if ($vars->{'json'})
|
303
|
14 |
4 |
if ($vars->{'pointer'}->contains($attr{'jpath'}))
|
305
|
4 |
10 |
'ARRAY' eq ref $value ? :
|
310
|
4 |
2 |
unless (exists $vars->{'dom'})
|
316
|
5 |
1 |
if ($vars->{'dom'})
|
321
|
5 |
0 |
unless (exists $vars->{'xml'})
|
326
|
0 |
1 |
if ($vars->{'xml'})
|
342
|
64 |
1 |
unless @input or $attr{'array'} or $attr{'hash'}
|
345
|
14 |
523 |
if @input > 1 and not $attr{'hash'}
|
347
|
9 |
528 |
if ($attr{'multiline'})
|
348
|
0 |
9 |
if ($attr{'array'}) { }
|
353
|
5 |
4 |
'Regexp' eq ref $attr{'multiline'} ? :
|
367
|
10 |
527 |
if $attr{'hash'} and $attr{'hash'} eq '1'
|
376
|
34 |
549 |
if ($attr{'hash'})
|
378
|
3 |
31 |
unless (@splitted == 2)
|
395
|
553 |
27 |
if $attr{'pre'}
|
398
|
567 |
13 |
if ($attr{'valid'})
|
399
|
188 |
379 |
if (my $error = $attr{'valid'}->($self, $out, \%attr))
|
404
|
35 |
153 |
if exists $attr{'default'}
|
407
|
19 |
169 |
if ($attr{'optional'})
|
409
|
6 |
13 |
unless defined $in
|
410
|
9 |
10 |
if defined $in and $in =~ /^\s*$/
|
414
|
141 |
47 |
if $error
|
426
|
64 |
516 |
if ($type and not defined $in)
|
427
|
6 |
58 |
if ($type eq 'bool')
|
430
|
3 |
3 |
exists $attr{'default'} ? :
|
433
|
6 |
58 |
if ($type eq 'logic')
|
439
|
384 |
196 |
if $attr{'post'}
|
444
|
4721 |
77 |
unless $conf->{'filters'}{$key}
|
449
|
38 |
39 |
if ($error)
|
454
|
8 |
30 |
if defined $attr{'default'}
|
456
|
1 |
37 |
if ($attr{'optional'})
|
458
|
0 |
1 |
unless defined $in
|
459
|
0 |
1 |
if defined $in and $in =~ /^\s*$/
|
463
|
30 |
8 |
if $error
|
474
|
572 |
8 |
if (defined $out or not $attr{'skipundef'})
|
476
|
30 |
542 |
if $attr{'hash'} and defined $key
|
482
|
4 |
38 |
if $attr{'array'} and not $attr{'optional'} and not @input
|
485
|
1 |
13 |
if $attr{'hash'} and not $attr{'optional'} and not @input
|
490
|
14 |
523 |
if ($attr{'hash'}) { }
|
|
42 |
481 |
elsif ($attr{'array'}) { }
|
493
|
7 |
35 |
if (defined $attr{'multijoin'}) { }
|
495
|
6 |
1 |
@output ? :
|
503
|
475 |
6 |
unless $attr{'skipundef'} and not defined $output[0]
|
507
|
537 |
0 |
if $conf->{'mojo_validator'}
|
510
|
13 |
456 |
wantarray ? :
|
517
|
0 |
444 |
unless defined $name
|
518
|
0 |
444 |
unless defined $def
|
522
|
0 |
123 |
do {
'ARRAY' eq ref $def
} ? :
|
|
0 |
123 |
do {
'CODE' eq ref $def
} ? :
|
|
2 |
123 |
do {
'Regexp' eq ref $def
} ? :
|
|
0 |
125 |
do {
'HASH' eq ref $def
} ? :
|
|
125 |
319 |
%attr ? :
|
543
|
0 |
1275 |
if $e
|
545
|
75 |
1200 |
unless $module->can('register')
|