@@ -15,11 +15,11 @@ import {
15 NONCUSTODIAL_WALLETS,
15 NONCUSTODIAL_WALLETS,
16 WALLET_TYPES,
16 WALLET_TYPES,
17} from 'lib/constants';
17} from 'lib/constants';
18−import { publicToAddress } from 'ethereumjs-util';
19import { getAuthToken } from 'lib/authToken';
18import { getAuthToken } from 'lib/authToken';
20import { BRIDGE_ERROR } from 'lib/error';
19import { BRIDGE_ERROR } from 'lib/error';
22import { useNetwork } from 'store/network';
21import { useNetwork } from 'store/network';
22+import { bufferedPublicKeyToAddress } from 'lib/utils/crypto';
24export const WalletContext = createContext(null);
24export const WalletContext = createContext(null);
@@ -94,7 +94,7 @@ function _useWallet(initialWallet = Nothing(), initialMnemonic = Nothing()) {
94 // force that public addresses are derived for each wallet
94 // force that public addresses are derived for each wallet
95 // NOTE wallet is Maybe<> and .map is Maybe#map
95 // NOTE wallet is Maybe<> and .map is Maybe#map
96 wallet.map(wal => {
96 wallet.map(wal => {
97− wal.address = wal.address || publicToAddress(wal.publicKey).toString('hex');
97+ wal.address = wal.address || bufferedPublicKeyToAddress(wal.publicKey);
98 return wal;
98 return wal;