Skip to content
Merged
Show file tree
Hide file tree
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
15 changes: 0 additions & 15 deletions modules/sdk-coin-hbar/src/lib/transaction.ts
Original file line number Diff line number Diff line change
Expand Up @@ -153,21 +153,6 @@ export class Transaction extends BaseTransaction {
}
});

// Handle self-transfer: when sender == recipient, the positive entry is filtered out above
// because its accountID matches the sender. Fall back to including it as the recipient.
if (transferData.length === 0 && transfers.length > 0) {
const selfTransferEntry = transfers.find((t) => Long.fromValue(t.amount!).isPositive());
if (selfTransferEntry) {
transferData.push({
address: stringifyAccountId(selfTransferEntry.accountID!),
amount: Long.fromValue(selfTransferEntry.amount!).toString(),
...(tokenTransfers.length && {
tokenName: tokenName,
}),
});
}
}

return {
...(tokenTransfers.length && {
tokenName: tokenName,
Expand Down

This file was deleted.

Loading