Skip to content

Commit 9584eb3

Browse files
committed
notification-hub: avoid false failure on gcm update output
AAZ output shaping no longer requires properties.gcmCredential; return {} when missing to avoid ResourceNotFoundError.
1 parent f49baf0 commit 9584eb3

File tree

1 file changed

+3
-1
lines changed
  • src/notification-hub/azext_notification_hub/aaz/latest/notification_hub/credential/gcm

1 file changed

+3
-1
lines changed

src/notification-hub/azext_notification_hub/aaz/latest/notification_hub/credential/gcm/_create.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,9 @@ def post_instance_create(self, instance):
9292
pass
9393

9494
def _output(self, *args, **kwargs):
95-
result = self.deserialize_output(self.ctx.selectors.subresource.required(), client_flatten=True)
95+
result = self.deserialize_output(self.ctx.selectors.subresource.get(), client_flatten=True)
96+
if result is None or result == AAZUndefined:
97+
return {}
9698
return result
9799

98100
class SubresourceSelector(AAZJsonSelector):

0 commit comments

Comments
 (0)