Skip to content

Commit

Permalink
address gutos feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
owencraston committed Nov 28, 2024
1 parent c615984 commit 6af5341
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion app/components/UI/Navbar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ import { RequestPaymentViewSelectors } from '../../../../e2e/selectors/Receive/R
import { MetricsEventBuilder } from '../../../core/Analytics/MetricsEventBuilder';
import { toChecksumHexAddress } from '@metamask/controller-utils';
///: BEGIN:ONLY_INCLUDE_IF(keyring-snaps)
import { isBtcAccount } from '../../../core/MultiChain/utils';
import { isBtcAccount } from '../../../core/Multichain/utils';
///: END:ONLY_INCLUDE_IF

const trackEvent = (event, params = {}) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import { useMetrics } from '../../../components/hooks/useMetrics';
import { CaipChainId } from '@metamask/utils';
import { KeyringClient } from '@metamask/keyring-api';
import { BitcoinWalletSnapSender } from '../../../core/SnapKeyring/BitcoinWalletSnap';
import { MultichainNetworks } from '../../../core/MultiChain/constants';
import { MultichainNetworks } from '../../../core/Multichain/constants';

Check failure on line 25 in app/components/Views/AddAccountActions/AddAccountActions.tsx

View workflow job for this annotation

GitHub Actions / scripts (lint:tsc)

Cannot find module '../../../core/Multichain/constants' or its corresponding type declarations.
import { useSelector } from 'react-redux';
import {
hasCreatedBtcMainnetAccount,
Expand Down
2 changes: 1 addition & 1 deletion app/components/hooks/useAccounts/useAccounts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import {
} from './useAccounts.types';
import { InternalAccount } from '@metamask/keyring-api';
import { BigNumber } from 'ethers';
import { getFormattedAddressFromInternalAccount } from '../../../core/MultiChain/utils';
import { getFormattedAddressFromInternalAccount } from '../../../core/Multichain/utils';

Check failure on line 34 in app/components/hooks/useAccounts/useAccounts.ts

View workflow job for this annotation

GitHub Actions / scripts (lint:tsc)

Cannot find module '../../../core/Multichain/utils' or its corresponding type declarations.

/**
* Hook that returns both wallet accounts and ens name information.
Expand Down
6 changes: 3 additions & 3 deletions app/selectors/accountsController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import {
isBtcMainnetAddress,
isBtcTestnetAddress,
///: END:ONLY_INCLUDE_IF
} from '../core/MultiChain/utils';
} from '../core/Multichain/utils';

Check failure on line 15 in app/selectors/accountsController.ts

View workflow job for this annotation

GitHub Actions / scripts (lint:tsc)

Cannot find module '../core/Multichain/utils' or its corresponding type declarations.

/**
*
Expand Down Expand Up @@ -99,7 +99,7 @@ export const selectCanSignTransactions = createSelector(

///: BEGIN:ONLY_INCLUDE_IF(keyring-snaps)
/**
* A selector that returns whether the the user has already created a Bitcoin mainnet account
* A selector that returns whether the user has already created a Bitcoin mainnet account
*/
export function hasCreatedBtcMainnetAccount(state: RootState): boolean {
const accounts = selectInternalAccounts(state);
Expand All @@ -109,7 +109,7 @@ export function hasCreatedBtcMainnetAccount(state: RootState): boolean {
}

/**
* A selector that returns whether the the user has already created a Bitcoin testnet account
* A selector that returns whether the user has already created a Bitcoin testnet account
*/
export function hasCreatedBtcTestnetAccount(state: RootState): boolean {
const accounts = selectInternalAccounts(state);
Expand Down
4 changes: 2 additions & 2 deletions app/util/address/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,15 +68,15 @@ describe('isENS', () => {
describe('renderSlightlyLongAddress', () => {
describe('with EVM addresses', () => {
const mockAddress = '0xC4955C0d639D99699Bfd7Ec54d9FaFEe40e4D272';
it('should return 5 characters before ellipsis and 4 final characters of the address after the ellipsis', () => {
it('returns 5 characters before ellipsis and 4 final characters of the address after the ellipsis', () => {
expect(renderSlightlyLongAddress(mockAddress).split('.')[0].length).toBe(
24,
);
expect(renderSlightlyLongAddress(mockAddress).split('.')[3].length).toBe(
4,
);
});
it('should return 0xC4955 before ellipsis and 4D272 after the ellipsis', () => {
it('returns 0xC4955 before ellipsis and 4D272 after the ellipsis', () => {
expect(renderSlightlyLongAddress(mockAddress, 5, 2).split('.')[0]).toBe(
'0xC4955',
);
Expand Down

0 comments on commit 6af5341

Please sign in to comment.