line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package WebService::Async::Onfido::Check; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
18
|
use strict; |
|
2
|
|
|
|
|
30
|
|
|
2
|
|
|
|
|
92
|
|
4
|
2
|
|
|
2
|
|
12
|
use warnings; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
61
|
|
5
|
|
|
|
|
|
|
|
6
|
2
|
|
|
2
|
|
11
|
use parent qw(WebService::Async::Onfido::Base::Check); |
|
2
|
|
|
|
|
7
|
|
|
2
|
|
|
|
|
26
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
our $VERSION = '0.006'; # VERSION |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
=head1 NAME |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
WebService::Async::Onfido::Check - represents data for Onfido |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
=head1 DESCRIPTION |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
=cut |
17
|
|
|
|
|
|
|
|
18
|
2
|
|
|
2
|
|
138
|
use Log::Any qw($log); |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
27
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
sub as_string { |
21
|
0
|
|
|
0
|
0
|
0
|
my ($self) = @_; |
22
|
|
|
|
|
|
|
|
23
|
0
|
|
|
|
|
0
|
return sprintf 'Check %s, result was %s (created %s as ID %s)', $self->status, $self->result, $self->created_at, $self->id; |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
0
|
|
0
|
0
|
0
|
0
|
sub applicant { return shift->{applicant} // die 'no applicant defined' } |
27
|
|
|
|
|
|
|
|
28
|
2
|
|
|
2
|
0
|
23
|
sub onfido { return shift->{onfido} } |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
sub reports { |
31
|
1
|
|
|
1
|
0
|
1696
|
my ($self, %args) = @_; |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
# return Ryu::Source->from($self->{reports}) if $self->{reports}; |
34
|
|
|
|
|
|
|
return $self->onfido->report_list( |
35
|
|
|
|
|
|
|
check_id => $self->id, |
36
|
|
|
|
|
|
|
%args |
37
|
1
|
|
|
2
|
|
5
|
)->map(sub { $log->debugf('Have report %s', $_->as_string); $_->{check} = $self; $_ }); |
|
2
|
|
|
|
|
68
|
|
|
2
|
|
|
|
|
18
|
|
|
2
|
|
|
|
|
19
|
|
38
|
|
|
|
|
|
|
} |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
1; |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
__END__ |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
=head1 AUTHOR |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
deriv.com C<< DERIV@cpan.org >> |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
=head1 LICENSE |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
Copyright deriv.com 2019. Licensed under the same terms as Perl itself. |
51
|
|
|
|
|
|
|
|