Skip to content

Commit

Permalink
Fix: errors reported by golangci-lint: S1009: should omit nil check; …
Browse files Browse the repository at this point in the history
…printf: non-constant format string
  • Loading branch information
Ioan Damian committed Sep 12, 2024
1 parent a9414f1 commit 5ac6219
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/awx/resource_job_template_launch.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ func resourceJobTemplateLaunchCreate(ctx context.Context, d *schema.ResourceData

if d.Get("wait_for_completion").(bool) {
err = jobTemplateLaunchWait(ctx, client.JobService, res, d.Timeout(schema.TimeoutCreate))
if err != nil {
if err != nil && len(err.Error()) > 0 {
return utils.Diagf(
"JobTemplate execution failure",
fmt.Sprintf("JobTemplateLaunch with ID %d and template ID %d, failed to complete %s", res.ID, d.Get("job_template_id").(int), err.Error()),

Check failure on line 134 in internal/awx/resource_job_template_launch.go

View workflow job for this annotation

GitHub Actions / Build

printf: non-constant format string in call to github.com/josh-silvas/terraform-provider-awx/tools/utils.Diagf (govet)
Expand Down

0 comments on commit 5ac6219

Please sign in to comment.