mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
[MMI] Don't group transactions by nonce if they are custodial Tx (#18982)
* adds mmi fence * adds comment and casts variable to bool * prettier
This commit is contained in:
parent
bf0a70dbba
commit
c4e1edef19
@ -251,7 +251,18 @@ export const nonceSortedTransactionsSelector = createSelector(
|
||||
txReceipt,
|
||||
} = transaction;
|
||||
|
||||
if (typeof nonce === 'undefined' || type === TransactionType.incoming) {
|
||||
// Don't group transactions by nonce if:
|
||||
// 1. Tx nonce is undefined
|
||||
// 2. Tx is incoming (deposit)
|
||||
// 3. Tx is custodial (mmi specific)
|
||||
let shouldNotBeGrouped =
|
||||
typeof nonce === 'undefined' || type === TransactionType.incoming;
|
||||
|
||||
///: BEGIN:ONLY_INCLUDE_IN(build-mmi)
|
||||
shouldNotBeGrouped = shouldNotBeGrouped || Boolean(transaction.custodyId);
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
|
||||
if (shouldNotBeGrouped) {
|
||||
const transactionGroup = {
|
||||
transactions: [transaction],
|
||||
initialTransaction: transaction,
|
||||
|
Loading…
Reference in New Issue
Block a user