File Coverage

blib/lib/WWW/TypePad/Util.pm
Criterion Covered Total %
statement 6 10 60.0
branch 0 2 0.0
condition n/a
subroutine 2 4 50.0
pod 0 1 0.0
total 8 17 47.0


line stmt bran cond sub pod time code
1             package WWW::TypePad::Util;
2 1     1   4 use strict;
  1         2  
  1         49  
3              
4 1     1   7 use List::Util qw( first );
  1         2  
  1         155  
5              
6             sub l {
7 0     0 0   my( $links, $rel ) = @_;
8 0     0     my $item = first { $_->{rel} eq $rel } @$links;
  0            
9 0 0         return $item ? $item->{href} : undef;
10             }
11              
12             1;