line |
true |
false |
branch |
26
|
0 |
0 |
unless $$self{'param'}{'nowarnings'} |
42
|
0 |
2 |
if (my $err = $self->_init(@_)) { } |
57
|
0 |
6 |
unless ($param =~ /^(username|password|nowarnings|proxy)$/) |
65
|
0 |
4 |
unless ($$self{'param'}{"$required"}) |
71
|
1 |
1 |
if (exists $$self{'param'}{'proxy'}) |
73
|
0 |
1 |
if ($@) |
113
|
0 |
0 |
unless ($key =~ /^(query|category|group|retention|minsize|maxsize|filetype|resultoffset|resultlimit|sortfield|sortorder)$/) |
121
|
0 |
0 |
unless ($criteria{"$req"}) |
135
|
0 |
0 |
if (exists $criteria{'category'}) |
136
|
0 |
0 |
if (ref($criteria{'category'}) =~ /^ARRAY/) { } |
|
0 |
0 |
elsif (not ref $criteria{'category'}) { } |
146
|
0 |
0 |
if (exists $criteria{'group'}) |
147
|
0 |
0 |
if (ref($criteria{'group'}) =~ /^ARRAY/) { } |
|
0 |
0 |
elsif (not ref $criteria{'group'}) { } |
157
|
0 |
0 |
if (exists $criteria{'retention'}) |
158
|
0 |
0 |
if ($criteria{'retention'} =~ /^\d+$/ and $criteria{'retention'} > 0) { } |
166
|
0 |
0 |
if (exists $criteria{'minsize'}) |
167
|
0 |
0 |
if ($criteria{'minsize'} =~ /\D/ or $criteria{'minsize'} < 0) { } |
|
0 |
0 |
elsif (exists $criteria{'maxsize'} and $criteria{'minsize'} > $criteria{'maxsize'}) { } |
180
|
0 |
0 |
if (exists $criteria{'maxsize'}) |
181
|
0 |
0 |
if ($criteria{'maxsize'} =~ /\D/ or $criteria{'maxsize'} < 0) { } |
|
0 |
0 |
elsif (exists $criteria{'minsize'} and $criteria{'minsize'} > $criteria{'maxsize'}) { } |
194
|
0 |
0 |
if (exists $criteria{'resultoffset'}) |
195
|
0 |
0 |
if ($criteria{'resultoffset'} =~ /\D/ or $criteria{'resultoffset'} < -1) { } |
204
|
0 |
0 |
if (exists $criteria{'resultlimit'}) |
205
|
0 |
0 |
if ($criteria{'resultlimit'} =~ /\D/ or $criteria{'resultlimit'} < 0) { } |
214
|
0 |
0 |
if (exists $criteria{'sortfield'}) |
215
|
0 |
0 |
if ($criteria{'sortfield'} ne NEWZBIN_SORTFIELD_DATE and $criteria{'sortfield'} ne NEWZBIN_SORTFIELD_SUBJECT and $criteria{'sortfield'} ne NEWZBIN_SORTFIELD_FILESIZE) { } |
228
|
0 |
0 |
if (exists $criteria{'sortorder'}) |
229
|
0 |
0 |
if ($criteria{'sortorder'} ne NEWZBIN_SORTORDER_ASC and $criteria{'sortorder'} ne NEWZBIN_SORTORDER_DESC) { } |
241
|
0 |
0 |
unless my $response = $ua->post('http://v3.newzbin.com/api/filefind3/', \%post, 'Content-type', 'application/x-www-form-urlencoded') |
248
|
0 |
0 |
unless ($response->is_success) |
249
|
0 |
0 |
if ($response->code == 500) { } |
|
0 |
0 |
elsif ($response->code == 403) { } |
|
0 |
0 |
elsif ($response->code == 402) { } |
263
|
0 |
0 |
if ($response->code == 204) |
314
|
0 |
0 |
unless ($key =~ /^(reportid|fileid|nogzip|leavegzipped)$/) |
321
|
0 |
0 |
if (exists $request{'reportid'} and exists $request{'fileid'}) { } |
|
0 |
0 |
elsif (not exists $request{'reportid'} || exists $request{'fileid'}) { } |
328
|
0 |
0 |
if (exists $request{'reportid'}) { } |
|
0 |
0 |
elsif (exists $request{'fileid'}) { } |
329
|
0 |
0 |
if ($request{'reportid'} =~ /\D/) |
334
|
0 |
0 |
if (ref($request{'fileid'}) =~ /^ARRAY/) { } |
336
|
0 |
0 |
if ($fid =~ /\D/) |
341
|
0 |
0 |
if ($request{'fileid'} =~ /\D/) |
349
|
0 |
0 |
$Compress::Zlib::VERSION ? : |
357
|
0 |
0 |
exists $request{'reportid'} ? : |
|
0 |
0 |
ref($request{'fileid'}) =~ /^ARRAY/ ? : |
|
0 |
0 |
exists $request{'fileid'} ? : |
|
0 |
0 |
!$request{'nogzip'} && $compress_zlib ? : |
364
|
0 |
0 |
unless ($response->is_success) |
365
|
0 |
0 |
if ($response->code == 500) { } |
|
0 |
0 |
elsif ($response->code == 503) { } |
|
0 |
0 |
elsif ($response->header('X-DNZB-RCode') =~ /^400/) { } |
|
0 |
0 |
elsif ($response->header('X-DNZB-RCode') =~ /^401/) { } |
|
0 |
0 |
elsif ($response->header('X-DNZB-RCode') =~ /^402/) { } |
|
0 |
0 |
elsif ($response->header('X-DNZB-RCode') =~ /^404/) { } |
|
0 |
0 |
elsif ($response->header('X-DNZB-RCode') =~ /^450/) { } |
390
|
0 |
0 |
$timeout =~ /\D/ ? : |
|
0 |
0 |
$timeout == 1 ? : |
398
|
0 |
0 |
if ($response->header('X-DNZB-RCode') =~ /^200/) { } |
403
|
0 |
0 |
if ($response->header('Content-Encoding') =~ /gzip/ and not $request{'leavegzipped'}) { } |
405
|
0 |
0 |
unless $nzb_file = Compress::Zlib::memGunzip($raw) |
410
|
0 |
0 |
if ($request{'reportid'}) { } |
|
0 |
0 |
elsif ($request{'fileid'}) { } |