line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
|
2
|
|
|
|
|
|
|
our $VERSION = '0.15'; |
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
use Catmandu::Sane; |
5
|
1
|
|
|
1
|
|
87375
|
use Moo; |
|
1
|
|
|
|
|
155509
|
|
|
1
|
|
|
|
|
7
|
|
6
|
1
|
|
|
1
|
|
264
|
use WWW::ORCID; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
5
|
|
7
|
1
|
|
|
1
|
|
676
|
use Catmandu::Fix::Has; |
|
1
|
|
|
|
|
4274
|
|
|
1
|
|
|
|
|
25
|
|
8
|
1
|
|
|
1
|
|
347
|
|
|
1
|
|
|
|
|
787
|
|
|
1
|
|
|
|
|
5
|
|
9
|
|
|
|
|
|
|
has path => (fix_arg => 1); |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
with 'Catmandu::Fix::Condition::SimpleAllTest'; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
my ($self, $var) = @_; |
14
|
|
|
|
|
|
|
"(is_value(${var}) && WWW::ORCID::API::Pub->new->get_bio(${var})->{'orcid-profile'})"; |
15
|
0
|
|
|
0
|
0
|
|
} |
16
|
0
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
=head1 NAME |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
Catmandu::Fix::Condition::is_live_orcid - test if the ORCID can be resolved |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
=head1 SYNOPSIS |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
if is_live_orcid(orcid) |
24
|
|
|
|
|
|
|
... |
25
|
|
|
|
|
|
|
else |
26
|
|
|
|
|
|
|
... |
27
|
|
|
|
|
|
|
end |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
=head1 SEE ALSO |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
L<Catmandu::Fix> |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
=cut |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
1; |