Skip to content

Commit 38f8acc

Browse files
authored
Fixes missing zones property in export Azure#2698 (Azure#2706)
1 parent ffabce1 commit 38f8acc

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

docs/CHANGELOG-v1.md

+3
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,9 @@ What's changed since v1.33.2:
6767
[#2689](https://github.com/Azure/PSRule.Rules.Azure/pull/2689)
6868
- Bump coverlet.collector to v6.0.1.
6969
[#2699](https://github.com/Azure/PSRule.Rules.Azure/pull/2699)
70+
- Bug fixes:
71+
- Fixed missing zones property for public IP addresses by @BernieWhite.
72+
[#2698](https://github.com/Azure/PSRule.Rules.Azure/issues/2698)
7073

7174
## v1.33.2
7275

src/PSRule.Rules.Azure/Pipeline/Export/ResourceExportVisitor.cs

+4-1
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,10 @@ private async Task GetProperties(ResourceContext context, JObject resource, stri
187187
return;
188188

189189
if (full.TryGetProperty(PROPERTY_PROPERTIES, out JObject properties))
190-
resource.Add(PROPERTY_PROPERTIES, properties);
190+
resource[PROPERTY_PROPERTIES] = properties;
191+
192+
if (full.TryGetProperty(PROPERTY_ZONES, out JArray zones))
193+
resource[PROPERTY_ZONES] = zones;
191194
}
192195

193196
/// <summary>

0 commit comments

Comments
 (0)