Skip to content

Commit

Permalink
Shortened error check logic
Browse files Browse the repository at this point in the history
  • Loading branch information
Dave Seepersad committed Sep 30, 2020
1 parent 1eb8e32 commit 876a03a
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions modules/azure/errors.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,7 @@ func ResourceNotFoundError(err error) bool {
if err != nil {
if autorestError, ok := err.(autorest.DetailedError); ok {
if requestError, ok := autorestError.Original.(*azure.RequestError); ok {
if requestError.ServiceError.Code == "ResourceNotFound" {
return true
}
return (requestError.ServiceError.Code == "ResourceNotFound")
}
}
}
Expand Down

0 comments on commit 876a03a

Please sign in to comment.