import { Reducer } from 'redux' ; import { TxSection , TxStatus } from '../../state/txs' ; import { ITxError } from '../actions/actionTypes' ; export const TxErrorReducer = ( state , action ) : TxSection => ( { ... state , [ action . tx_hash ] : { ... state [ action . tx_hash ] , status : TxStatus . Error , e : action . e } } ) ;