domeneshop: Treat all 2xx as success

This commit is contained in:
Richard Hansen 2024-07-19 18:43:22 -04:00
parent b4e08ae3ae
commit d391f41074

View file

@ -4328,18 +4328,10 @@ sub nic_domeneshop_update {
next; next;
} }
next if !header_ok($h, $reply); next if !header_ok($h, $reply);
my @reply = split /\n/, $reply; $config{$h}{'ip'} = $ip;
my $status = shift(@reply); $config{$h}{'mtime'} = $now;
my $message = pop(@reply); $config{$h}{'status'} = 'good';
if ($status =~ /204/) { success("$h: IP address set to $ip");
$config{$h}{'ip'} = $ip;
$config{$h}{'mtime'} = $now;
$config{$h}{'status'} = 'good';
success("$h: IP address set to $ip");
} else {
$config{$h}{'status'} = 'failed';
failed("$h: Server said: $status $message");
}
} }
} }