Skip to content

Commit 9ae104c

Browse files
author
guyinyou
committed
golang:
compatible with some abnormal scenarios, such as flowlimit
1 parent 2306251 commit 9ae104c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

golang/push_consumer.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ func (pc *defaultPushConsumer) changeInvisibleDuration(messageView *MessageView,
128128
return fmt.Errorf("changeInvisibleDuration failed, err = the message is nil")
129129
}
130130
resp, err := pc.changeInvisibleDuration0(context.Background(), messageView, invisibleDuration)
131-
if resp != nil {
131+
if err == nil && resp != nil {
132132
messageView.ReceiptHandle = resp.ReceiptHandle
133133
}
134134
return err

0 commit comments

Comments
 (0)