X-Git-Url: http://gb7djk.dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=cmd%2Fdisconnect.pl;h=e8e83b89c4778f18f5c730e7c5c2d858dd9a1236;hb=4647d4d8a9a97117b29c7b3a0477de2e76c01194;hp=51ddc696e4a54bf62abf593ffff9a552a1531f15;hpb=6a0068ec3df1dca0c6ae2714af3c0a4a62998dcf;p=spider.git diff --git a/cmd/disconnect.pl b/cmd/disconnect.pl index 51ddc696..e8e83b89 100644 --- a/cmd/disconnect.pl +++ b/cmd/disconnect.pl @@ -6,8 +6,8 @@ my @calls = split /\s+/, $line; my $call; my @out; -if ($self->priv < 9) { - return (1, "not allowed"); +if ($self->priv < 8) { + return (1, $self->msg('e5')); } foreach $call (@calls) { @@ -16,13 +16,14 @@ foreach $call (@calls) { my $dxchan = DXChannel->get($call); if ($dxchan) { if ($dxchan->is_ak1a) { - $dxchan->send_now("D", DXProt::pc39($main::mycall, 'Disconnected')); + $dxchan->send_now("D", DXProt::pc39($main::mycall, $self->msg('disc1', $self->call))); } else { - $dxchan->disconnect; + $dxchan->send_now('D', $self->msg('disc1', $self->call)); } - push @out, "disconnected $call"; + $dxchan->disconnect; + push @out, $self->msg('disc2', $call); } else { - push @out, "$call not connected locally"; + push @out, $self->msg('e10', $call); } }