Fix firewall rules destination_ports handling when nil

Co-authored-by: oscarhermoso <23239955+oscarhermoso@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2025-11-26 05:13:34 +00:00
parent e15930ed7e
commit cc03603386
@@ -262,6 +262,8 @@ func GetFirewallRulesState(ctx context.Context, firewallRules *[]binarylane.Adva
if rule.DestinationPorts != nil {
destinationPorts, diag = types.ListValueFrom(ctx, types.StringType, rule.DestinationPorts)
diags.Append(diag...)
} else {
destinationPorts = types.ListNull(types.StringType)
}
sourceAddresses, diag := types.ListValueFrom(ctx, types.StringType, rule.SourceAddresses)