Skip to content

Commit

Permalink
Merge pull request #2517 from near/eslint-nonexistent-imports
Browse files Browse the repository at this point in the history
style(lint): nonexistent named imports error
  • Loading branch information
MaximusHaximus authored Mar 9, 2022
2 parents 1596f38 + 5297768 commit e5e0dec
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 14 deletions.
4 changes: 4 additions & 0 deletions packages/frontend/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ module.exports = {
'no-extra-boolean-cast':'off',
'no-extra-semi':'off',
'no-irregular-whitespace':'off',
'import/named': ['error', 'always'],
'import/order': [
'error',
{
Expand Down Expand Up @@ -53,6 +54,9 @@ module.exports = {
'message': 'Please use a selector for any state accesses within useSelector'
}]
},
settings: {
'import/ignore': ['src/config/*'],
},
overrides: [
{
files: [
Expand Down
12 changes: 0 additions & 12 deletions packages/frontend/src/redux/reducers/account/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,10 @@ import reduceReducers from 'reduce-reducers';
import { handleActions } from 'redux-actions';

import {
requestCode,
getAccessKeys,
clearCode,
promptTwoFactor,
refreshUrl,
resetAccounts,
checkCanEnableTwoFactor,
get2faMethod,
getLedgerKey,
Expand Down Expand Up @@ -38,12 +36,6 @@ const initialState = {
};

const recoverCodeReducer = handleActions({
[requestCode]: (state, { error, ready }) => {
if (ready && !error) {
return { ...state, sentMessage: true };
}
return state;
},
[clearCode]: (state, { error, ready }) => {
return { ...state, sentMessage: false };
}
Expand Down Expand Up @@ -126,10 +118,6 @@ const account = handleActions({
loader: false
};
},
[resetAccounts]: (state) => ({
...state,
loginResetAccounts: true
}),
[staking.updateAccount]: (state, { ready, error, payload }) =>
(!ready || error)
? state
Expand Down
3 changes: 1 addition & 2 deletions packages/frontend/src/routes/LoginWrapper.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@ import { useSelector } from 'react-redux';
import ConfirmLoginWrapper from '../components/login/v2/ConfirmLoginWrapper';
import InvalidContractId from '../components/login/v2/InvalidContractId';
import SelectAccountLoginWrapper from '../components/login/v2/SelectAccountLoginWrapper';
import { EXPLORER_URL } from '../config';
import { EXPLORER_URL, LOCKUP_ACCOUNT_ID_SUFFIX } from '../config';
import { Mixpanel } from '../mixpanel/index';
import {
selectAccountLocalStorageAccountId
} from '../redux/slices/account';
import { isUrlNotJavascriptProtocol } from '../utils/helper-api';
import { LOCKUP_ACCOUNT_ID_SUFFIX } from '../utils/wallet';

export const LOGIN_ACCESS_TYPES = {
FULL_ACCESS: 'fullAccess',
Expand Down

0 comments on commit e5e0dec

Please sign in to comment.