Skip to content

Commit

Permalink
Use pointer.From to perform nil check
Browse files Browse the repository at this point in the history
Co-authored-by: stephybun <[email protected]>
  • Loading branch information
EppO and stephybun authored Jan 29, 2025
1 parent d8a31ad commit b0c31c0
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,7 @@ func dataSourcePrivateDnsZoneVirtualNetworkLinkRead(d *pluginsdk.ResourceData, m
if props := model.Properties; props != nil {
d.Set("registration_enabled", props.RegistrationEnabled)

if resolutionPolicy := props.ResolutionPolicy; resolutionPolicy != nil {
d.Set("resolution_policy", string(*resolutionPolicy))
}

d.Set("resolution_policy", pointer.From(props.ResolutionPolicy))

Check failure on line 87 in internal/services/privatedns/private_dns_zone_virtual_network_link_data_source.go

View workflow job for this annotation

GitHub Actions / document-lint

undefined: pointer
if network := props.VirtualNetwork; network != nil {
d.Set("virtual_network_id", network.Id)
}
Expand Down

0 comments on commit b0c31c0

Please sign in to comment.