line |
true |
false |
branch |
36
|
1 |
48 |
if (my $name = $when->{'field'}) { }
|
|
0 |
48 |
elsif (my $names = $when->{'fields'}) { }
|
40
|
1 |
0 |
if (defined $field)
|
41
|
0 |
1 |
if DEBUG_CONSTRAINTS()
|
55
|
0 |
0 |
if (defined $field)
|
68
|
15 |
394 |
unless $self->_run_this_rep
|
75
|
29 |
365 |
unless ($self->_process_when($params))
|
76
|
0 |
29 |
if DEBUG_CONSTRAINTS()
|
80
|
14 |
351 |
if (ref $value eq 'ARRAY') { }
|
83
|
1 |
13 |
if ($@)
|
94
|
0 |
351 |
if DEBUG_CONSTRAINTS()
|
95
|
0 |
351 |
if DEBUG_CONSTRAINTS()
|
97
|
115 |
236 |
$@ || !$ok ? :
|
110
|
382 |
61 |
unless my $only_on_reps = $self->only_on_reps
|
113
|
0 |
61 |
unless my $current_rep = $self->field->repeatable_count
|
116
|
18 |
43 |
if (&reftype($only_on_reps) || '') ne 'ARRAY'
|
130
|
10 |
384 |
if (@fields_with_this_name > 1)
|
135
|
10 |
5 |
if ($fields_with_this_name[$i] eq $field)
|
141
|
0 |
10 |
unless defined $index
|
144
|
10 |
0 |
if ((&reftype($value) || '') eq 'ARRAY') { }
|
|
0 |
0 |
elsif ($index == 0) { }
|
167
|
0 |
45 |
if DEBUG_CONSTRAINTS()
|
168
|
0 |
45 |
if DEBUG_CONSTRAINTS()
|
170
|
1 |
44 |
$@ || !$ok ? :
|
193
|
130 |
274 |
if (CORE::not $pass or $force)
|
196
|
8 |
122 |
if $pass
|
207
|
198 |
0 |
unless (&blessed($err) and $err->isa('HTML::FormFu::Exception::Constraint'))
|
224
|
429 |
76 |
unless defined $when
|
227
|
0 |
76 |
if ref $when ne 'HASH'
|
237
|
0 |
76 |
if &all(sub {
CORE::not defined $_;
}
, $when_field, $when_fields, $when_any_field, $when_callback)
|
241
|
20 |
56 |
if ($when_callback)
|
250
|
10 |
46 |
if ($when_any_field)
|
251
|
0 |
10 |
unless @$when_any_field
|
258
|
17 |
39 |
if ($when_fields) { }
|
259
|
0 |
17 |
unless @$when_fields
|
264
|
54 |
0 |
if defined $value
|
273
|
39 |
0 |
if defined $value
|
277
|
0 |
56 |
if DEBUG_CONSTRAINTS_WHEN()
|
280
|
0 |
56 |
unless (@when_fields_value)
|
281
|
0 |
0 |
if DEBUG_CONSTRAINTS_WHEN()
|
288
|
24 |
32 |
if (defined(my $value = $when->{'value'})) { }
|
|
10 |
22 |
elsif (defined(my $values = $when->{'values'})) { }
|
298
|
34 |
22 |
if (@values) { }
|
305
|
29 |
30 |
$value ? :
|
309
|
0 |
56 |
if DEBUG_CONSTRAINTS_WHEN()
|
313
|
0 |
21 |
$when->{'not'} ? :
|
314
|
14 |
35 |
$when->{'not'} ? :
|
|
10 |
46 |
$any ? :
|
316
|
0 |
56 |
if DEBUG_CONSTRAINTS_WHEN()
|
338
|
1 |
50 |
if (defined(my $when = $self->when))
|