infomaniak: Fail if the HTTP status code is not 2xx

This commit is contained in:
Richard Hansen 2024-06-25 22:23:27 -04:00
parent 7d99da77cc
commit 9ba583175a

View file

@ -8019,10 +8019,7 @@ sub nic_infomaniak_update {
login => $config{$h}{'login'},
password => $config{$h}{'password'},
);
if (!$reply) {
failed("could not update %s", $h);
next;
}
next if !header_ok($h, $reply);
(my $body = $reply) =~ s/^.*?\n\n//s;
my ($status) = split(/ /, $body, 2);
my ($ok, $msg) =