removed need for token address

This commit is contained in:
Nouman Tahir 2022-02-22 15:34:21 +05:00
parent ac4544b109
commit 52834509f4
2 changed files with 1 additions and 6 deletions

View File

@ -42,7 +42,6 @@ export interface CoinActivity {
}
interface State {
tokenAddress:string;
selectedCoins:CoinBase[];
coinsData:{
[key: string]: CoinData;
@ -57,7 +56,6 @@ interface State {
}
const initialState:State = {
tokenAddress:'',
selectedCoins:DEFAULT_COINS,
coinsData:{},
priceHistories:{},
@ -77,7 +75,6 @@ export default function (state = initialState, action) {
case SET_COINS_DATA:{
return {
...state,
//TODO: pass and asign tokenAddress
coinsData:payload,
updateTimestamp:new Date().getTime()
}

View File

@ -32,7 +32,6 @@ const CoinDetailsScreen = ({navigation}:CoinDetailsScreenProps) => {
const currentAccount = useAppSelector(state=>state.account.currentAccount);
const globalProps = useAppSelector(state=>state.account.globalProps);
const tokenAddress = useAppSelector(state=>state.wallet.tokenAddress);
const selectedCoins = useAppSelector(state=>state.wallet.selectedCoins);
const coinData:CoinData = useAppSelector(state=>state.wallet.coinsData[coinId]);
const coinActivities:CoinActivity[] = useAppSelector(state=>state.wallet.coinsActivities[coinId]);
@ -74,8 +73,7 @@ const CoinDetailsScreen = ({navigation}:CoinDetailsScreenProps) => {
navigateParams = {
transferType:coinId === COIN_IDS.ECENCY?'points':transferType,
fundType:coinId === COIN_IDS.ECENCY?'ESTM':symbol,
balance,
tokenAddress
balance
};
}