Skip to content

fix(chat): return to the group after buying in from its gate - #1532

Merged
bmc08gt merged 1 commit into
code/cashfrom
fix/chat-gate-buy-return
Sep 23, 2026
Merged

bmc08gt merged 1 commit into
code/cashfrom
fix/chat-gate-buy-return

Conversation

@bmc08gt

@bmc08gt bmc08gt commented Sep 23, 2026

Copy link
Copy Markdown
Collaborator

Buy More on a group's gate opens Token Info over the chat. Buying from there closed only the swap, so the reader landed on Token Info instead of back at Join.

AppRoute.Token.Info gains returnAfterBuy, set only by GroupGateBar through ChatAction.ViewToken(mint, returnAfterBuy = true). When the swap returns SwapResult.Success for a buy of that mint, TokenInfoScreen pops itself and the chat is on top again.

The mint check is there because Add Money from Token Info also ends in a successful buy, of USDF, to fund the real purchase. That returns to Token Info as before, unless USDF is the gate's currency, in which case the deposit is what gets the reader in.

Swap results are queued until Token Info is back on top, so Token Info shows briefly before it pops.

Buy More on a group's gate opens Token Info over the chat, and buying from
there only closed the swap, leaving the reader on Token Info with no way
back to Join except the back arrow.

Token.Info now takes returnAfterBuy, which the gate sets. When a buy of that
currency succeeds, Token Info closes too and the chat is back on top.
Add Money from Token Info also ends in a successful buy, but of USDF, so it
only counts when USDF is the gate's currency. Token taps in the transcript
open Token Info as before.
@bmc08gt bmc08gt self-assigned this Sep 23, 2026
@github-actions github-actions Bot added type: fix Bug fix area: tokens Token accounts, balances, token info and removed type: fix Bug fix labels Sep 23, 2026
@bmc08gt
bmc08gt merged commit cfe9329 into code/cash Sep 23, 2026
3 checks passed
@bmc08gt
bmc08gt deleted the fix/chat-gate-buy-return branch September 23, 2026 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: tokens Token accounts, balances, token info

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant