Skip to content

Commit 88954c5

Browse files
committed
Adding null check for export_format
1 parent 577c10c commit 88954c5

2 files changed

Lines changed: 50 additions & 50 deletions

File tree

src/azure-cli/azure/cli/command_modules/resource/custom.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1721,7 +1721,7 @@ def export_group_as_template(
17211721
for detail in getattr(error, 'details', None) or []:
17221722
logger.error(detail.message)
17231723

1724-
return result.output if export_format.lower() == "bicep" else result.template
1724+
return result.output if export_format and export_format.lower() == "bicep" else result.template
17251725

17261726

17271727
def create_application(cmd, resource_group_name,

0 commit comments

Comments
 (0)