WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Makefile.PL
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ recommends 'JSON' => '2.9';
recommends 'LWP::Simple' => '6.00';
recommends 'LWP::UserAgent' => '6.05';
recommends 'PAR::Dist' => '0.29';

suggests 'CPANPLUS' => '0'; # used by AutoInstall, when installed

# Remove some extra test files
clean_files( qw{ t/Foo } );
Expand Down
12 changes: 6 additions & 6 deletions lib/Module/AutoInstall.pm
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ sub do_install {
__PACKAGE__->install(
[
$Config
? ( UNIVERSAL::isa( $Config, 'HASH' ) ? %{$Config} : @{$Config} )
? ( ref($Config) eq 'HASH' ? %{$Config} : @{$Config} )
: ()
],
@Missing,
Expand Down Expand Up @@ -162,7 +162,7 @@ sub import {

print "[" . ( $FeatureMap{ lc($feature) } || $feature ) . "]\n";

$modules = [ %{$modules} ] if UNIVERSAL::isa( $modules, 'HASH' );
$modules = [ %{$modules} ] if ref($modules) eq 'HASH';

unshift @$modules, -default => &{ shift(@$modules) }
if ( ref( $modules->[0] ) eq 'CODE' ); # XXX: bugward compatibility
Expand Down Expand Up @@ -423,7 +423,7 @@ sub _install_cpanplus {

# if we're root, set UNINST=1 to avoid trouble unless user asked for it.
my $makeflags = $conf->get_conf('makeflags') || '';
if ( UNIVERSAL::isa( $makeflags, 'HASH' ) ) {
if ( ref($makeflags) eq 'HASH' ) ) {
# 0.03+ uses a hashref here
$makeflags->{UNINST} = 1 unless exists $makeflags->{UNINST};

Expand Down Expand Up @@ -690,7 +690,7 @@ sub _can_write {
.
my $missing = join( ',', @Missing );
my $config = join( ',',
UNIVERSAL::isa( $Config, 'HASH' ) ? %{$Config} : @{$Config} )
ref($Config) eq 'HASH' ? %{$Config} : @{$Config} )
if $Config;

return
Expand Down Expand Up @@ -818,7 +818,7 @@ sub _make_args {

my $missing = join( ',', @Missing );
my $config =
join( ',', UNIVERSAL::isa( $Config, 'HASH' ) ? %{$Config} : @{$Config} )
join( ',', (ref($Config) eq 'HASH' ? %{$Config} : @{$Config} ))
if $Config;

$PostambleActions = (
Expand All @@ -833,7 +833,7 @@ sub _make_args {
"\$(PERL) $0 --config=$config --upgradedeps=$deps_list";

my $config_notest =
join( ',', (UNIVERSAL::isa( $Config, 'HASH' ) ? %{$Config} : @{$Config}),
join( ',', (ref($Config) eq 'HASH' ? %{$Config} : @{$Config} ))
'notest', 1 )
if $Config;

Expand Down