]> dxcluster.net Git - spider.git/blob - cmd/stat/user.pl
fix DXVars.pm overrides line $clusterport
[spider.git] / cmd / stat / user.pl
1 #
2 # show either the current user or a nominated set
3 #
4 #
5 #
6
7 my ($self, $line) = @_;
8 my @list = split /\s+/, $line;  # generate a list of callsigns
9 @list = ($self->call) if !@list; # my channel if no callsigns
10
11 my $call;
12 my @out;
13 foreach $call (@list) {
14         $call = uc $call;
15         my $ref = DXUser::get_current($call);
16         if ($ref) {
17                 if ($self->consort eq 'ax25') {
18                         @out = grep { !/(Password|Privilege)/ } print_all_fields($self, $ref, "User Information $call");
19                 } else {
20                         @out = print_all_fields($self, $ref, "User Information $call");
21                 }
22         } else {
23                 push @out, "User: $call not found";
24         }
25         push @out, "" if @list > 1;
26 }
27
28 return (1, @out);