Skip to content

Commit

Permalink
Update internal/services/paymentdispatchers/circle_payment_dispatcher.go
Browse files Browse the repository at this point in the history
Co-authored-by: Marwen Abid <[email protected]>
  • Loading branch information
marcelosalloum and marwen-abid committed Jan 16, 2025
1 parent e2caa97 commit ccffb78
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ func (c *CirclePaymentDispatcher) sendPaymentsToCircle(ctx context.Context, sdpD
var cAPIErr *circle.APIError
// 5.1. If the destination address is invalid, mark the recipient as failed
if errors.As(err, &cAPIErr) && slices.Contains(circle.DestinationAddressErrorCodes, cAPIErr.Code) {
log.Ctx(ctx).Error("the destination address is deemed invalid by Circle, marking the recipient as pending...")
log.Ctx(ctx).Error("the destination address is deemed invalid by Circle, marking the recipient as denied...")
_, cRecipientUpdateErr := c.sdpModels.CircleRecipient.Update(ctx, recipient.ReceiverWalletID, data.CircleRecipientUpdate{Status: data.CircleRecipientStatusDenied})
if cRecipientUpdateErr != nil {
return fmt.Errorf("updating Circle recipient status: %w", cRecipientUpdateErr)
Expand Down

0 comments on commit ccffb78

Please sign in to comment.