fixed sh/c/n
[spider.git] / cmd / unset / here.pl
1 #
2 # unset the here flag
3 #
4 # Copyright (c) 1998 - Dirk Koopman
5 #
6 # $Id$
7 #
8
9 my ($self, $line) = @_;
10 my @args = split /\s+/, $line;
11 my $call;
12 my @out;
13
14 @args = $self->call if (!@args || $self->priv < 9);
15
16 foreach $call (@args) {
17   $call = uc $call;
18   my $dxchan = DXChannel->get($call);
19   my $ref = DXCluster->get($call);
20   if ($dxchan && $ref) {
21         $dxchan->here(0);
22     $ref->here(0);
23         DXProt::broadcast_ak1a(DXProt::pc24($ref));
24         push @out, $self->msg('hereu', $call);
25   } else {
26     push @out, $self->msg('e3', "Unset Here", $call);
27   }
28 }
29 return (1, @out);