Merge pull request #11829 from hashicorp/b-aws-test-fixes
provider/aws: Set the qualifier to an empty string if the parsing fai…
This commit is contained in:
commit
b1a70b5560
|
@ -211,9 +211,10 @@ func resourceAwsLambdaPermissionRead(d *schema.ResourceData, meta interface{}) e
|
|||
}
|
||||
|
||||
qualifier, err := getQualifierFromLambdaAliasOrVersionArn(statement.Resource)
|
||||
if err == nil {
|
||||
d.Set("qualifier", qualifier)
|
||||
if err != nil {
|
||||
log.Printf("[ERR] Error getting Lambda Qualifier: %s", err)
|
||||
}
|
||||
d.Set("qualifier", qualifier)
|
||||
|
||||
// Save Lambda function name in the same format
|
||||
if strings.HasPrefix(d.Get("function_name").(string), "arn:"+meta.(*AWSClient).partition+":lambda:") {
|
||||
|
|
Loading…
Reference in New Issue