Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions modules/sdk-coin-sol/src/sol.ts
Original file line number Diff line number Diff line change
Expand Up @@ -562,9 +562,10 @@ export class Sol extends BaseCoin {
}
}

const isTokenEnablementTx = txParams.type === 'enabletoken';
// users do not input recipients for consolidation requests as they are generated by the server
// Close-ATA txs do not populate explainedTx.outputs; recipients carry ATA addresses for intent only.
if (txParams.recipients !== undefined && !isCloseAssociatedTokenAccountTx) {
if (txParams.recipients !== undefined && !isTokenEnablementTx && !isCloseAssociatedTokenAccountTx) {
const filteredRecipients = txParams.recipients?.map((recipient) =>
_.pick(recipient, ['address', 'amount', 'tokenName'])
);
Expand Down Expand Up @@ -662,7 +663,7 @@ export class Sol extends BaseCoin {
if (memo && memo.value !== explainedTx.memo) {
throw new Error('Tx memo does not match with expected txParams recipient memo');
}
if (txParams.recipients && !isCloseAssociatedTokenAccountTx) {
if (txParams.recipients && !isTokenEnablementTx && !isCloseAssociatedTokenAccountTx) {
for (const recipients of txParams.recipients) {
// totalAmount based on each token
const assetName = recipients.tokenName || this.getChain();
Expand Down
Loading