Skip to content

Commit

Permalink
return err when createService failed
Browse files Browse the repository at this point in the history
  • Loading branch information
astj committed Jul 28, 2020
1 parent 77e7dca commit 9426b5d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion check-aws-sqs-queue-size/lib/check-aws-sqs-queue-size.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ func createService(region, awsAccessKeyID, awsSecretAccessKey string) (*sqs.SQS,
func getSqsQueueSize(region, awsAccessKeyID, awsSecretAccessKey, queueName string) (int, error) {
sqsClient, err := createService(region, awsAccessKeyID, awsSecretAccessKey)
if err != nil {
return -1, nil
return -1, err
}

// Get queue url
Expand Down

0 comments on commit 9426b5d

Please sign in to comment.