From abf8823cf1711c507a1b8e96c3711731892b3df2 Mon Sep 17 00:00:00 2001 From: Andre Medeiros Date: Thu, 8 Jul 2021 20:37:39 -0400 Subject: [PATCH] use .Err to invoke the command --- cmd/apollo-worker-notifications/main.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cmd/apollo-worker-notifications/main.go b/cmd/apollo-worker-notifications/main.go index 3b0b88d..599df24 100644 --- a/cmd/apollo-worker-notifications/main.go +++ b/cmd/apollo-worker-notifications/main.go @@ -182,7 +182,9 @@ func NewConsumer(tag int, logger *logrus.Logger, statsd *statsd.Client, redis *r func (c *Consumer) Consume(delivery rmq.Delivery) { ctx := context.Background() - defer c.redis.HDel(ctx, "locks:accounts", delivery.Payload()) + defer func() { + c.redis.HDel(ctx, "locks:accounts", delivery.Payload()).Err() + }() c.logger.WithFields(logrus.Fields{ "accountID": delivery.Payload(),