mirror of
https://github.com/trezor/trezor-wallet
synced 2024-11-24 01:08:27 +00:00
quickfix: disable REQUEST_WALLET_TYPE action for device without passphrase_protection
This commit is contained in:
parent
6a3e71f0a5
commit
0f39182db7
@ -167,10 +167,19 @@ export const requestWalletType = (): AsyncAction => async (dispatch: Dispatch, g
|
|||||||
const isDeviceReady = selected.connected && selected.features && !selected.state && selected.mode === 'normal' && selected.firmware !== 'required';
|
const isDeviceReady = selected.connected && selected.features && !selected.state && selected.mode === 'normal' && selected.firmware !== 'required';
|
||||||
if (!isDeviceReady) return;
|
if (!isDeviceReady) return;
|
||||||
|
|
||||||
dispatch({
|
if (selected.features && selected.features.passphrase_protection) {
|
||||||
type: CONNECT.REQUEST_WALLET_TYPE,
|
dispatch({
|
||||||
device: selected,
|
type: CONNECT.REQUEST_WALLET_TYPE,
|
||||||
});
|
device: selected,
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
dispatch({
|
||||||
|
type: CONNECT.RECEIVE_WALLET_TYPE,
|
||||||
|
device: selected,
|
||||||
|
hidden: false,
|
||||||
|
state: selected.state,
|
||||||
|
});
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
export const authorizeDevice = (): AsyncAction => async (dispatch: Dispatch, getState: GetState): Promise<void> => {
|
export const authorizeDevice = (): AsyncAction => async (dispatch: Dispatch, getState: GetState): Promise<void> => {
|
||||||
|
Loading…
Reference in New Issue
Block a user