increase refresh intervals

This commit is contained in:
Tyler Shipe 2021-04-21 11:21:00 -04:00
parent 4de2c58ebb
commit d9eee98f5e
1 changed files with 3 additions and 2 deletions

View File

@ -10,6 +10,7 @@ import {
import { WalletAdapter } from '../@types/types'
import useInterval from './useInterval'
const SECONDS = 1000
const ASSET_URL =
'https://cdn.jsdelivr.net/gh/solana-labs/oyster@main/assets/wallets'
@ -143,13 +144,13 @@ export default function useWallet() {
actions.fetchMarginAccounts()
actions.fetchWalletBalances()
}
}, 15000)
}, 20 * SECONDS)
useInterval(() => {
if (connected && marginAccount) {
actions.fetchTradeHistory()
}
}, 60000)
}, 180 * SECONDS)
return { connected, wallet }
}