Skip to content

Commit

Permalink
Merge pull request #21 from plicease-pr/graham/list-util
Browse files Browse the repository at this point in the history
use List::Util instead of List::MoreUtils for any and none
  • Loading branch information
nigelhorne authored Jan 10, 2025
2 parents 100e0fa + 34a7a7d commit d8343da
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Makefile.PL
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ WriteMakefile(
'File::Spec' => 3.4,
'Cwd' => 0,
'Socket' => 0,
'List::MoreUtils' => 0,
'List::Util' => 1.33,
'HTTP::BrowserDetect' => 3.10, # Include bingbot
'File::Basename' => 0,
'String::Clean::XSS' => 0,
Expand Down
6 changes: 3 additions & 3 deletions lib/CGI/Info.pm
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use 5.008;
use Log::Any qw($log);
# use Cwd;
# use JSON::Parse;
use List::MoreUtils; # Can go when expect goes
use List::Util (); # Can go when expect goes
# use Sub::Private;
use Sys::Path;

Expand Down Expand Up @@ -752,7 +752,7 @@ sub params {
}
}

if($self->{expect} && (List::MoreUtils::none { $_ eq $key } @{$self->{expect}})) {
if($self->{expect} && (List::Util::none { $_ eq $key } @{$self->{expect}})) {
next;
}
$value = _sanitise_input($value);
Expand Down Expand Up @@ -1434,7 +1434,7 @@ sub is_robot {
'http://www.seokicks.de/robot.html',
);
$referrer =~ s/\\/_/g;
if(($referrer =~ /\)/) || (List::MoreUtils::any { $_ =~ /^$referrer/ } @crawler_lists)) {
if(($referrer =~ /\)/) || (List::Util::any { $_ =~ /^$referrer/ } @crawler_lists)) {
$self->_debug("is_robot: blocked trawler $referrer");

if($self->{cache}) {
Expand Down

0 comments on commit d8343da

Please sign in to comment.