mirror of
https://github.com/trezor/trezor-wallet
synced 2025-01-29 17:31:00 +00:00
remove comments
This commit is contained in:
parent
128d238037
commit
b7790c0351
@ -60,27 +60,4 @@ export const prepareEthereumTx = (tx: EthereumTxRequest): PromiseAction<Ethereum
|
||||
export const serializeEthereumTx = (tx: EthereumTransaction): PromiseAction<string> => async (): Promise<string> => {
|
||||
const ethTx = new EthereumjsTx(tx);
|
||||
return `0x${ethTx.serialize().toString('hex')}`;
|
||||
};
|
||||
|
||||
// type RippleTxRequest = {
|
||||
// network: string;
|
||||
// from: string;
|
||||
// to: string;
|
||||
// amount: string;
|
||||
// data: string;
|
||||
// gasLimit: string;
|
||||
// gasPrice: string;
|
||||
// nonce: number;
|
||||
// }
|
||||
|
||||
// export const prepareRippleTx = (tx: RippleTxRequest): PromiseAction<RippleTransaction> => async (dispatch: Dispatch): Promise<RippleTransaction> => {
|
||||
// // TODO: fetch account sequence
|
||||
// return {
|
||||
// fee: string,
|
||||
// flags?: number,
|
||||
// sequence?: number,
|
||||
// maxLedgerVersion?: number, // Proto: "last_ledger_sequence"
|
||||
// payment: Payment,
|
||||
// }
|
||||
|
||||
// };
|
||||
};
|
@ -17,7 +17,6 @@ import * as AccountsActions from 'actions/AccountsActions';
|
||||
|
||||
export const discoverAccount = (device: TrezorDevice, address: string, network: string): PromiseAction<EthereumAccount> => async (dispatch: Dispatch): Promise<EthereumAccount> => {
|
||||
// get data from connect
|
||||
// Temporary disabled, enable after trezor-connect@5.0.32 release
|
||||
const txs = await TrezorConnect.ethereumGetAccountInfo({
|
||||
account: {
|
||||
address,
|
||||
@ -35,7 +34,6 @@ export const discoverAccount = (device: TrezorDevice, address: string, network:
|
||||
|
||||
// blockbook web3 fallback
|
||||
const web3account = await dispatch(Web3Actions.discoverAccount(address, network));
|
||||
// return { transactions: txs.payload, ...web3account };
|
||||
return {
|
||||
address,
|
||||
transactions: txs.payload.transactions,
|
||||
|
@ -36,7 +36,6 @@ export const discoverAccount = (device: TrezorDevice, discoveryProcess: Discover
|
||||
const { accountIndex } = discoveryProcess;
|
||||
const path = network.bip44.slice(0).replace('a', accountIndex.toString());
|
||||
|
||||
// $FlowIssue npm not released yet
|
||||
const response = await TrezorConnect.rippleGetAccountInfo({
|
||||
device: {
|
||||
path: device.path,
|
||||
|
@ -72,7 +72,7 @@ export const observe = (prevState: ReducersState, action: Action): ThunkAction =
|
||||
|
||||
/*
|
||||
* Called from "observe" action
|
||||
* Initialize "sendForm" reducer data
|
||||
* Initialize "sendFormRipple" reducer data
|
||||
* Get data either from session storage or "selectedAccount" reducer
|
||||
*/
|
||||
export const init = (): AsyncAction => async (dispatch: Dispatch, getState: GetState): Promise<void> => {
|
||||
@ -85,7 +85,6 @@ export const init = (): AsyncAction => async (dispatch: Dispatch, getState: GetS
|
||||
|
||||
const stateFromStorage = dispatch(SessionStorageActions.loadRippleDraftTransaction());
|
||||
if (stateFromStorage) {
|
||||
// TODO: consider if current gasPrice should be set here as "recommendedGasPrice"
|
||||
dispatch({
|
||||
type: SEND.INIT,
|
||||
networkType: 'ripple',
|
||||
|
Loading…
Reference in New Issue
Block a user