diff options
-rw-r--r-- | lib/App/ArchLinux/PackagerTools.pm | 1 | ||||
-rwxr-xr-x | script/perlpkg.pl | 3 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/App/ArchLinux/PackagerTools.pm b/lib/App/ArchLinux/PackagerTools.pm index 0bd602a..0fbd224 100644 --- a/lib/App/ArchLinux/PackagerTools.pm +++ b/lib/App/ArchLinux/PackagerTools.pm @@ -38,6 +38,7 @@ Returns a new instance. =cut method new($class: $deps = {}) { + $deps->{context} //= {}; $deps->{config} //= App::ArchLinux::PackagerTools::Config->new({$deps->%{context}}); $deps->{cpan} //= App::ArchLinux::PackagerTools::CPAN->new({$deps->%{context}}); $deps->{pacman} //= App::ArchLinux::PackagerTools::Pacman->new({$deps->%{context}}); diff --git a/script/perlpkg.pl b/script/perlpkg.pl index f66b9d6..e6cac27 100755 --- a/script/perlpkg.pl +++ b/script/perlpkg.pl @@ -48,8 +48,7 @@ if ($ARGV[0] // "" eq "--debug") { } Log::Any::Adapter->set('Log4perl'); -my $context = {}; -my $app = App::ArchLinux::PackagerTools->new({context => $context}); +my $app = App::ArchLinux::PackagerTools->new(); use Data::Dumper; my $dists = $app->get_distributions_in_repo(); |