From 0d92872d9096af7f41a01ccc2d9a18a7ec706645 Mon Sep 17 00:00:00 2001 From: alfred-mk Date: Wed, 25 Feb 2026 13:35:48 +0300 Subject: [PATCH] ensure that any stable coin can do a direct transfer to Mpesa --- handlers/application/mpesa.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/handlers/application/mpesa.go b/handlers/application/mpesa.go index cdb5415..30a5b4e 100644 --- a/handlers/application/mpesa.go +++ b/handlers/application/mpesa.go @@ -103,8 +103,10 @@ func (h *MenuHandlers) GetMpesaMaxLimit(ctx context.Context, sym string, input [ minksh := fmt.Sprintf("%f", config.MinMpesaWithdrawAmount()) minKshFormatted, _ := store.TruncateDecimalString(minksh, 0) - // If SAT is the same as RAT, return early with KSH format - if string(metadata.TokenAddress) == string(recipientActiveAddress) { + // If SAT is the same as RAT (default USDm), + // or if the voucher is a stable coin + // return early with KSH format + if string(metadata.TokenAddress) == string(recipientActiveAddress) || isStableVoucher(metadata.TokenAddress) { txType = "normal" // Save the transaction type if err := userStore.WriteEntry(ctx, sessionId, storedb.DATA_SEND_TRANSACTION_TYPE, []byte(txType)); err != nil {