mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-22 09:57:02 +01:00
Fix order of account list (#12999)
This commit is contained in:
parent
889e49a4a2
commit
bdc7e1df57
@ -1,8 +1,8 @@
|
||||
import { connect } from 'react-redux';
|
||||
import {
|
||||
accountsWithSendEtherInfoSelector,
|
||||
getAddressBook,
|
||||
getAddressBookEntry,
|
||||
getMetaMaskAccountsOrdered,
|
||||
} from '../../../../selectors';
|
||||
|
||||
import {
|
||||
@ -34,9 +34,7 @@ function mapStateToProps(state) {
|
||||
|
||||
const addressBook = getAddressBook(state);
|
||||
|
||||
const ownedAccounts = accountsWithSendEtherInfoSelector(state).sort((a, b) =>
|
||||
a.name.localeCompare(b.name),
|
||||
);
|
||||
const ownedAccounts = getMetaMaskAccountsOrdered(state);
|
||||
|
||||
return {
|
||||
addressBook,
|
||||
|
@ -12,7 +12,7 @@ jest.mock('react-redux', () => ({
|
||||
jest.mock('../../../../selectors', () => ({
|
||||
getAddressBook: (s) => [{ name: `mockAddressBook:${s}` }],
|
||||
getAddressBookEntry: (s) => `mockAddressBookEntry:${s}`,
|
||||
accountsWithSendEtherInfoSelector: () => [
|
||||
getMetaMaskAccountsOrdered: () => [
|
||||
{ name: `account1:mockState` },
|
||||
{ name: `account2:mockState` },
|
||||
],
|
||||
|
Loading…
Reference in New Issue
Block a user