Skip to content

Commit

Permalink
fix issue when wlan.ap_ids has null value
Browse files Browse the repository at this point in the history
  • Loading branch information
tmunzer committed Dec 20, 2024
1 parent 2e28064 commit d397810
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 2 deletions.
15 changes: 15 additions & 0 deletions docs/guides/release_note_0.2.14.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
subcategory: "Release Notes"
page_title: "v0.2.14"
description: |-
Release Notes for v0.2.14
---

# Release Notes for v0.2.14

**version** : v0.2.13
**release date** : December 20th, 2024


## Fixes
* Fixing issue when `mist_org_wlan.ap_ids` or `mist_org_wlan.ap_ids` is present but has an `null` value
2 changes: 1 addition & 1 deletion internal/resource_org_wlan/sdk_to_terraform.go
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ func SdkToTerraform(ctx context.Context, data *models.Wlan) (OrgWlanModel, diag.
allow_ssdp = types.BoolValue(*data.AllowSsdp)
}

if data.ApIds.IsValueSet() && len(*data.ApIds.Value()) > 0 {
if data.ApIds.Value() != nil && len(*data.ApIds.Value()) > 0 {
ap_ids = mist_transform.ListOfUuidSdkToTerraform(ctx, *data.ApIds.Value())
}

Expand Down
2 changes: 1 addition & 1 deletion internal/resource_site_wlan/sdk_to_terraform.go
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ func SdkToTerraform(ctx context.Context, data *models.Wlan) (SiteWlanModel, diag
allow_ssdp = types.BoolValue(*data.AllowSsdp)
}

if data.ApIds.IsValueSet() && len(*data.ApIds.Value()) > 0 {
if data.ApIds.Value() != nil && len(*data.ApIds.Value()) > 0 {
ap_ids = mist_transform.ListOfUuidSdkToTerraform(ctx, *data.ApIds.Value())
}

Expand Down
15 changes: 15 additions & 0 deletions templates/guides/release_note_0.2.14.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
subcategory: "Release Notes"
page_title: "v0.2.14"
description: |-
Release Notes for v0.2.14
---

# Release Notes for v0.2.14

**version** : v0.2.13
**release date** : December 20th, 2024


## Fixes
* Fixing issue when `mist_org_wlan.ap_ids` or `mist_org_wlan.ap_ids` is present but has an `null` value

1 comment on commit d397810

@tmunzer
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#63

Please sign in to comment.