Fix nil ptr deference when listing client queues

Signed-off-by: Cecylia Bocovich <cohosh@torproject.org>
This commit is contained in:
Michael Pu 2024-01-31 12:09:05 -05:00 committed by Cecylia Bocovich
parent 9b90b77d69
commit b8df42a377
No known key found for this signature in database
GPG key ID: 009DE379FD9B7B90

View file

@ -71,6 +71,8 @@ func (r *sqsHandler) cleanupClientQueues(ctx context.Context) {
})
if err != nil {
log.Printf("SQSHandler: encountered error while retrieving client queues to clean up: %v\n", err)
// client queues will be cleaned up the next time the cleanup operation is triggered automatically
break
}
queueURLsList = append(queueURLsList, res.QueueUrls...)
if res.NextToken == nil {