Skip to content

Commit

Permalink
azurerm_resource_deployment_script_* - fix issue where identity w…
Browse files Browse the repository at this point in the history
…asn't specified but was being sent as `TypeNone` to the api (#22165)
  • Loading branch information
ms-zhenhua authored Jun 15, 2023
1 parent ab0c9aa commit ca63a09
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,9 @@ func (r ResourceDeploymentScriptAzureCliResource) Create() sdk.ResourceFunc {
return err
}

properties.Identity = identityValue
if identityValue != nil && identityValue.Type != identity.TypeNone {
properties.Identity = identityValue
}

if model.Arguments != "" {
properties.Properties.Arguments = &model.Arguments
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,9 @@ func (r ResourceDeploymentScriptAzurePowerShellResource) Create() sdk.ResourceFu
return err
}

properties.Identity = identityValue
if identityValue != nil && identityValue.Type != identity.TypeNone {
properties.Identity = identityValue
}

if model.Arguments != "" {
properties.Properties.Arguments = &model.Arguments
Expand Down

0 comments on commit ca63a09

Please sign in to comment.