| line | % | coverage | branch |
| 202 | 100 | T | F | if (not defined $class) { } |
| 100 | T | F | elsif (&Scalar::Util::blessed($class)) { } |
| 207 | 100 | T | F | if (exists $params->{'ua'}) |
| 208 | 50 | T | F | if (not defined $params->{'ua'}) { } |
| 50 | T | F | elsif (not &Scalar::Util::blessed($params->{'ua'}) && $params->{'ua'}->can('get')) { } |
| 224 | 100 | T | F | if ($params->{'host'}) |
| 225 | 50 | T | F | unless my($safe_host) = $params->{'host'} =~ /\A([A-Za-z0-9][A-Za-z0-9.\-]*(:\d{1,5})?)\z/ |
| 231 | 100 | T | F | unless (defined $ua) |
| 364 | 100 | T | F | if (scalar @_ == 2 and &Scalar::Util::blessed($_[0]) and $_[0]->can('latitude')) { } |
| 373 | 100 | T | F | if $_[0]->can("tz") and $ENV{'TIMEZONEDB_KEY'} |
| 384 | 100 | T | F | if (not defined $latitude and defined $location and &Scalar::Util::blessed($location) and $location->can("latitude")) |
| 390 | 100 | T | F | unless (defined $latitude and defined $longitude and defined $date) |
| 392 | 50 | T | F | if $self->{'logger'} |
| 403 | 100 | T | F | unless (defined $lat_clean and defined $lon_clean) |
| 405 | 50 | T | F | if $self->{'logger'} |
| 411 | 100 | T | F | if (&Scalar::Util::blessed($date) and $date->can('strftime')) { } |
| 100 | T | F | elsif ($date =~ /^(\d{4})-/) { } |
| 414 | 100 | T | F | if $1 < 1940 |
| 420 | 100 | T | F | unless ($date =~ /^\d{4}-\d{2}-\d{2}$/) |
| 422 | 50 | T | F | if $self->{'logger'} |
| 427 | 100 | T | F | if (my $cached = $self->{'cache'}->get($cache_key)) |
| 448 | 100 | T | F | unless defined $rc and ref $rc eq "HASH" |
| 450 | 100 | T | F | if ($rc->{'error'}) |
| 455 | 50 | T | F | if $self->{'logger'} |
| 460 | 100 | T | F | unless defined $rc->{'hourly'} |
| 566 | 100 | T | F | if (scalar @_ >= 1 and &Scalar::Util::blessed($_[0]) and $_[0]->can('latitude')) { } |
| 573 | 100 | T | F | if defined $_[1] |
| 575 | 0 | T | F | if $location->can("tz") and $ENV{'TIMEZONEDB_KEY'} |
| 586 | 0 | T | F | if (not defined $latitude and defined $location and &Scalar::Util::blessed($location) and $location->can("latitude")) |
| 592 | 100 | T | F | unless (defined $latitude and defined $longitude) |
| 594 | 50 | T | F | if $self->{'logger'} |
| 603 | 100 | T | F | unless (defined $lat_clean and defined $lon_clean) |
| 605 | 50 | T | F | if $self->{'logger'} |
| 611 | 100 | T | F | if (not $days =~ /^\d+$/ or $days < 1 or $days > 16) |
| 617 | 100 | T | F | if (my $cached = $self->{'cache'}->get($cache_key)) |
| 636 | 50 | T | F | unless defined $rc and ref $rc eq "HASH" |
| 637 | 50 | T | F | if $rc->{'error'} |
| 638 | 50 | T | F | unless defined $rc->{'hourly'} |
| 756 | 100 | T | F | if (scalar @_ >= 1 and &Scalar::Util::blessed($_[0]) and $_[0]->can('latitude')) { } |
| 763 | 50 | T | F | if defined $_[1] |
| 765 | 0 | T | F | if $location->can("tz") and $ENV{'TIMEZONEDB_KEY'} |
| 775 | 0 | T | F | if (not defined $latitude and defined $location and &Scalar::Util::blessed($location) and $location->can("latitude")) |
| 781 | 100 | T | F | unless (defined $latitude and defined $longitude) |
| 783 | 50 | T | F | if $self->{'logger'} |
| 792 | 50 | T | F | unless (defined $lat_clean and defined $lon_clean) |
| 794 | 0 | T | F | if $self->{'logger'} |
| 804 | 50 | T | F | if (defined $date and &Scalar::Util::blessed($date) and $date->can("strftime")) |
| 808 | 100 | T | F | if (defined $date and not $date =~ /^\d{4}-\d{2}-\d{2}$/) |
| 818 | 100 | T | F | if (my $cached = $self->{'cache'}->get($cache_key)) |
| 822 | 50 | T | F | $use_forecast ? : |
| 823 | 50 | T | F | $use_forecast ? : |
| 836 | 50 | T | F | unless defined $rc and ref $rc eq "HASH" and not $rc->{'error'} |
| 839 | 50 | T | F | unless ref $daily eq "HASH" |
| 841 | 50 | T | F | ref $daily->{'sunrise'} eq 'ARRAY' ? : |
| 842 | 50 | T | F | ref $daily->{'sunset'} eq 'ARRAY' ? : |
| 843 | 50 | T | F | unless defined $sr and defined $ss |
| 903 | 100 | T | F | if (@_) |
| 914 | 100 | T | F | unless (defined $params->{'ua'}) |
| 915 | 50 | T | F | if $self->{'logger'} |
| 937 | 100 | T | F | if (my($frac) = $result =~ /\A-\.((?>\d+))\z/) { } |
| 100 | T | F | elsif ($result =~ /\A\./) { } |
| 953 | 100 | T | F | if ($elapsed < $self->{'min_interval'}) |
| 978 | 100 | T | F | unless (defined $res and ref $res and $res->can("is_error")) |
| 983 | 100 | T | F | if ($res->is_error) |
| 990 | 100 | T | F | if ($@) |
| 995 | 100 | T | F | if length $err > 200 |