summaryrefslogtreecommitdiffstats
path: root/lib/ASM/Commander.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/ASM/Commander.pm')
-rw-r--r--lib/ASM/Commander.pm5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/ASM/Commander.pm b/lib/ASM/Commander.pm
index d864800..c1f93ef 100644
--- a/lib/ASM/Commander.pm
+++ b/lib/ASM/Commander.pm
@@ -35,7 +35,10 @@ sub command
next unless (defined($command->{nohush}) && ($command->{nohush} eq "nohush"));
}
if (defined($command->{flag})) { #If the command is restricted,
- if (!defined($::users->{person}->{$acct})) { #make sure the requester has an account
+ if (!defined($acct)) {
+ $fail = 1;
+ }
+ elsif (!defined($::users->{person}->{$acct})) { #make sure the requester has an account
$fail = 1;
}
elsif (!defined($::users->{person}->{$acct}->{flags})) { #make sure the requester has flags defined