porkbun: Whitespace fixes
This commit is contained in:
parent
4b5b8ab62d
commit
3f740c3e19
1 changed files with 15 additions and 19 deletions
|
@ -6767,7 +6767,6 @@ EoEXAMPLE
|
|||
######################################################################
|
||||
sub nic_porkbun_update {
|
||||
debug("\nnic_porkbun_update -------------------");
|
||||
|
||||
for my $host (@_) {
|
||||
my ($sub_domain, $domain);
|
||||
if ($config{$host}{'root-domain'}) {
|
||||
|
@ -6790,17 +6789,14 @@ sub nic_porkbun_update {
|
|||
($sub_domain, $domain) = split(/\./, $host, 2);
|
||||
}
|
||||
info("subdomain %s, root domain %s", $sub_domain, $domain) if $sub_domain ne '';
|
||||
|
||||
for my $ipv ('ipv4', 'ipv6') {
|
||||
my $ip = delete $config{$host}{"want$ipv"};
|
||||
if (!$ip) {
|
||||
next;
|
||||
}
|
||||
my $rrset_type = is_ipv6($ip) ? "AAAA" : "A";
|
||||
|
||||
info("setting %s address to %s for %s", $ipv, $ip, $host);
|
||||
verbose("UPDATE:","updating %s", $host);
|
||||
|
||||
my $url = "https://porkbun.com/api/json/v3/dns/retrieveByNameType/$domain/$rrset_type/$sub_domain";
|
||||
my $data = encode_json({
|
||||
secretapikey => $config{$host}{'secretapikey'},
|
||||
|
|
Loading…
Reference in a new issue