2 # set any variable in the User file
4 # This is a hack - use the UTMOST CAUTION!!!!!!!!
6 # Copyright (c) 1999 Dirk Koopman G1TLH
10 my ($self, $line) = @_;
12 my @args = split /\s+/, $line;
13 return (1, $self->msg('suser1')) if @args < 3;
16 my $call = uc $args[0];
17 my $ref = DXUser->get_current($call);
21 return (1, $self->msg('suser2', $call)) unless $ref;
22 return (1, $self->msg('suser4', $field)) unless $ref->field_prompt($field);
25 # set it (dates and silly things like that can come later)
27 if ($self->priv < 9 || $self->remotecmd || $self->inscript) {
28 Log('DXCommand', $self->call . " attempted to set user var $field=$value on $call remotely");
29 push @out, $self->msg('sorry');
32 my $oldvalue = $ref->{$field};
33 $ref->{$field} = $value;
36 push @out, $self->msg('suser3', $field, $oldvalue, $value);
37 push @out, print_all_fields($self, $ref, "User Information $call");