handle normal send transactions based on the sym

This commit is contained in:
Alfred Kamanda 2025-10-30 11:12:16 +03:00
parent 8ce17a8d1e
commit 582f349be3
Signed by: Alfred-mk
GPG Key ID: E60B2165A97F4D41

View File

@ -335,8 +335,8 @@ func (h *MenuHandlers) MaxAmount(ctx context.Context, sym string, input []byte)
// Format the active balance amount to 2 decimal places
formattedBalance, _ := store.TruncateDecimalString(string(activeBal), 2)
// If normal transaction, return balance
if string(transactionType) == "normal" {
// If normal transaction, or if the sym is max_amount, return balance
if string(transactionType) == "normal" || sym == "max_amount" {
res.FlagReset = append(res.FlagReset, flag_swap_transaction)
res.Content = l.Get("Maximum amount: %s %s\nEnter amount:", formattedBalance, string(activeSym))