fix error with undefined err
This commit is contained in:
parent
312f2dd6e3
commit
449ffe027f
|
@ -153,7 +153,7 @@ func resourceAwsLambdaFunctionCreate(d *schema.ResourceData, meta interface{}) e
|
|||
// http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html#launch-instance-with-role-console
|
||||
// Error creating Lambda function: InvalidParameterValueException: The role defined for the task cannot be assumed by Lambda.
|
||||
err := resource.Retry(1*time.Minute, func() error {
|
||||
_, err = conn.CreateFunction(params)
|
||||
_, err := conn.CreateFunction(params)
|
||||
if err != nil {
|
||||
if awserr, ok := err.(awserr.Error); ok {
|
||||
if awserr.Code() == "InvalidParameterValueException" {
|
||||
|
|
Loading…
Reference in New Issue