diff --git a/internal/service/lambda/recursion_config.go b/internal/service/lambda/recursion_config.go index f8d89759055..72e42a10e5b 100644 --- a/internal/service/lambda/recursion_config.go +++ b/internal/service/lambda/recursion_config.go @@ -58,7 +58,7 @@ func (r *resourceRecursionConfig) Metadata(_ context.Context, req resource.Metad func (r *resourceRecursionConfig) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) { resp.Schema = schema.Schema{ Attributes: map[string]schema.Attribute{ - "id": framework.IDAttribute(), + names.AttrID: framework.IDAttribute(), "function_name": schema.StringAttribute{ Description: "The name of the Lambda function.", Required: true, @@ -80,7 +80,7 @@ func (r *resourceRecursionConfig) Schema(ctx context.Context, req resource.Schem }, }, Blocks: map[string]schema.Block{ - "timeouts": timeouts.Block(ctx, timeouts.Opts{ + names.AttrTimeouts: timeouts.Block(ctx, timeouts.Opts{ Create: true, Update: true, Delete: true, @@ -190,7 +190,6 @@ func (r *resourceRecursionConfig) Update(ctx context.Context, req resource.Updat planFunctionName := plan.FunctionName.ValueString() if !plan.RecursiveLoop.Equal(state.RecursiveLoop) { - in := &lambda.PutFunctionRecursionConfigInput{ FunctionName: flex.StringFromFramework(ctx, plan.ID), } @@ -231,7 +230,6 @@ func (r *resourceRecursionConfig) Update(ctx context.Context, req resource.Updat if resp.Diagnostics.HasError() { return } - } resp.Diagnostics.Append(resp.State.Set(ctx, &plan)...) diff --git a/internal/service/lambda/recursion_config_test.go b/internal/service/lambda/recursion_config_test.go index a94a79b2bb3..662bf5cf80d 100644 --- a/internal/service/lambda/recursion_config_test.go +++ b/internal/service/lambda/recursion_config_test.go @@ -260,7 +260,7 @@ func testAccRecursionConfigConfig_basic(rName string) string { testAccRecursionConfigConfigBase(rName), ` resource "aws_lambda_recursion_config" "test" { - function_name = aws_lambda_function.test.function_name + function_name = aws_lambda_function.test.function_name recursive_loop = "Terminate" } `) @@ -271,7 +271,7 @@ func testAccRecursionConfigConfig_updateRecursiveLoop(rName, resRecursiveLoopVal testAccRecursionConfigConfigBase(rName), fmt.Sprintf(` resource "aws_lambda_recursion_config" "test" { - function_name = aws_lambda_function.test.function_name + function_name = aws_lambda_function.test.function_name recursive_loop = %[1]q } `, resRecursiveLoopValue))