From: Vincent Pit Date: Sun, 3 Oct 2010 11:56:00 +0000 (+0200) Subject: Make register check $SKIP directly X-Git-Tag: v0.04~12 X-Git-Url: http://git.vpit.fr/?a=commitdiff_plain;h=a5999baca9fcb63b31909c4352e4e3e655156eb2;p=perl%2Fmodules%2FAcme-CPANAuthors-You-re_using.git Make register check $SKIP directly Otherwise calling it as a class method would not do anything. --- diff --git a/lib/Acme/CPANAuthors/You/re_using.pm b/lib/Acme/CPANAuthors/You/re_using.pm index 7c08bb6..9f5a818 100644 --- a/lib/Acme/CPANAuthors/You/re_using.pm +++ b/lib/Acme/CPANAuthors/You/re_using.pm @@ -48,8 +48,10 @@ This function is automatically called when you C this module, unless you ha BEGIN { require Acme::CPANAuthors::Register; } +our $SKIP; + sub register { - return if shift; + return if $SKIP; my %authors; @@ -85,9 +87,7 @@ sub register { Acme::CPANAuthors::Register->import(%authors); } -our $SKIP; - -BEGIN { register($SKIP) } +BEGIN { register() } =head1 DEPENDENCIES