diff --git a/lib/Nipe/Engine/Start.pm b/lib/Nipe/Engine/Start.pm index 281e2cc..fdb401c 100644 --- a/lib/Nipe/Engine/Start.pm +++ b/lib/Nipe/Engine/Start.pm @@ -5,7 +5,7 @@ use warnings; use Nipe::Utils::Device; sub new { - my %device = Nipe::Utils::Device -> new(); + my %device = Nipe::Utils::Device -> new(); my $dnsPort = "9061"; my $transferPort = "9051"; my @table = ("nat", "filter"); diff --git a/nipe.pl b/nipe.pl index 38f8754..8fdbd3c 100755 --- a/nipe.pl +++ b/nipe.pl @@ -12,13 +12,12 @@ use Nipe::Utils::Status; use Nipe::Utils::Helper; use Nipe::Utils::Install; - sub main { - die "Nipe must be run as root.\n" if $> != 0; - my $argument = $ARGV[0]; if ($argument) { + die "Nipe must be run as root.\n" if $> != 0; + my $commands = { stop => "Nipe::Engine::Stop", start => "Nipe::Engine::Start",