line |
true |
false |
branch |
43
|
74 |
0 |
unless exists $conf->{'date'}
|
44
|
74 |
0 |
unless exists $conf->{'time'}
|
45
|
73 |
1 |
unless exists $conf->{'datetime'}
|
60
|
0 |
74 |
'version'->new($Mojolicious::VERSION) < 'version'->new(4.42) ? :
|
65
|
1999 |
1 |
if @_ > 2
|
72
|
1111 |
1 |
if @_ > 2
|
79
|
6 |
1 |
if @_ > 2
|
89
|
363 |
174 |
if (@_ <= 2) { }
|
|
5 |
169 |
elsif (@_ == 3) { }
|
90
|
237 |
126 |
unless exists $errors->{$name}
|
94
|
5 |
121 |
'ARRAY' eq ref $errors->{$name} ? :
|
97
|
0 |
5 |
unless exists $errors->{$name}
|
101
|
5 |
0 |
'ARRAY' eq ref $errors->{$name} ? :
|
107
|
13 |
156 |
if ($attr{'array'}) { }
|
108
|
12 |
1 |
unless exists $errors->{$name}
|
114
|
169 |
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 |
459 |
exists $params{-'optional'} ? :
|
174
|
0 |
460 |
exists $params{-'skipundef'} ? :
|
178
|
0 |
460 |
exists $params{-'multiline'} ? :
|
182
|
0 |
460 |
exists $params{-'blessed'} ? :
|
193
|
223 |
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 |
528 |
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
|
515 |
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
|
513 |
2 |
if (exists $conf->{'types'}{$type}) { }
|
248
|
10 |
1413 |
if defined $attr{$key}
|
257
|
98 |
428 |
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
|
19 |
507 |
if ($attr{'jpath'}) { }
|
|
6 |
501 |
elsif ($attr{'cpath'}) { }
|
|
5 |
496 |
elsif ($attr{'xpath'}) { }
|
278
|
18 |
1 |
if ($vars->{'json'})
|
281
|
14 |
4 |
if ($vars->{'pointer'}->contains($attr{'jpath'}))
|
283
|
4 |
10 |
'ARRAY' eq ref $value ? :
|
291
|
5 |
1 |
if ($vars->{'dom'})
|
299
|
0 |
1 |
if ($vars->{'xml'})
|
315
|
59 |
1 |
unless @input or $attr{'array'} or $attr{'hash'}
|
318
|
14 |
508 |
if @input > 1 and not $attr{'hash'}
|
320
|
9 |
513 |
if ($attr{'multiline'})
|
321
|
0 |
9 |
if ($attr{'array'}) { }
|
326
|
5 |
4 |
'Regexp' eq ref $attr{'multiline'} ? :
|
340
|
8 |
514 |
if $attr{'hash'} and $attr{'hash'} eq '1'
|
351
|
28 |
536 |
if ($attr{'hash'})
|
353
|
3 |
25 |
unless (@splitted == 2)
|
370
|
534 |
27 |
if $attr{'pre'}
|
373
|
548 |
13 |
if ($attr{'valid'})
|
374
|
175 |
373 |
if (my $error = $attr{'valid'}->($self, $out, \%attr))
|
379
|
35 |
140 |
if exists $attr{'default'}
|
381
|
17 |
158 |
if ($attr{'optional'})
|
383
|
6 |
11 |
unless defined $in
|
384
|
7 |
10 |
if defined $in and $in =~ /^\s*$/
|
388
|
130 |
45 |
if $error
|
400
|
59 |
502 |
if ($type and not defined $in)
|
401
|
6 |
53 |
if ($type eq 'bool')
|
404
|
3 |
3 |
exists $attr{'default'} ? :
|
407
|
6 |
53 |
if ($type eq 'logic')
|
413
|
365 |
196 |
if $attr{'post'}
|
418
|
4550 |
77 |
unless $conf->{'filters'}{$key}
|
423
|
38 |
39 |
if ($error)
|
428
|
8 |
30 |
if defined $attr{'default'}
|
430
|
1 |
37 |
if ($attr{'optional'})
|
432
|
0 |
1 |
unless defined $in
|
433
|
0 |
1 |
if defined $in and $in =~ /^\s*$/
|
437
|
30 |
8 |
if $error
|
448
|
553 |
8 |
if (defined $out or not $attr{'skipundef'})
|
450
|
24 |
529 |
if $attr{'hash'} and defined $key
|
456
|
4 |
38 |
if $attr{'array'} and not $attr{'optional'} and not @input
|
459
|
1 |
11 |
if $attr{'hash'} and not $attr{'optional'} and not @input
|
464
|
12 |
510 |
if ($attr{'hash'}) { }
|
|
42 |
468 |
elsif ($attr{'array'}) { }
|
467
|
7 |
35 |
if (defined $attr{'multijoin'}) { }
|
469
|
6 |
1 |
@output ? :
|
477
|
462 |
6 |
unless $attr{'skipundef'} and not defined $output[0]
|
481
|
522 |
0 |
if $conf->{'mojo_validator'}
|
484
|
13 |
441 |
wantarray ? :
|
491
|
0 |
429 |
unless defined $name
|
492
|
0 |
429 |
unless defined $def
|
496
|
0 |
108 |
do {
'ARRAY' eq ref $def
} ? :
|
|
0 |
108 |
do {
'CODE' eq ref $def
} ? :
|
|
2 |
108 |
do {
'Regexp' eq ref $def
} ? :
|
|
0 |
110 |
do {
'HASH' eq ref $def
} ? :
|
|
110 |
319 |
%attr ? :
|
517
|
0 |
1258 |
if $e
|
519
|
74 |
1184 |
unless $module->can('register')
|