2 # Add/modify a USDB entry
4 # There are no checks and NO balances.
6 # Copyright (c) 2002 Dirk Koopman
11 my ($self, $line) = @_;
12 return (1, $self->msg('e5')) if $self->priv < 9;
14 my ($call, $state, $city) = split /\s+/, uc $line, 3;
15 return (1, $self->msg('susdb1')) if length $state != 2 || !is_callsign($call);
17 my ($ocity, $ostate) = USDB::get($call);
19 push @out, $self->msg('susdb2', $call, $ocity, $ostate ) if $ocity;
20 USDB::add($call, $city, $state);
21 push @out, $self->msg('susdb3', $call, $city, $state );
22 Log('DXCommand', $self->msg('susdb3', $call, $city, $state));