use finalized blockhashes; remove saving old blockhashes
This commit is contained in:
parent
19da795035
commit
813cd3c1c9
|
@ -249,19 +249,6 @@ const useHydrateStore = () => {
|
|||
actions.loadMarketFills()
|
||||
}, 20 * SECONDS)
|
||||
|
||||
useInterval(() => {
|
||||
const blockhashTimes = useMangoStore.getState().connection.blockhashTimes
|
||||
const blockhashTimesCopy = [...blockhashTimes]
|
||||
const mangoClient = useMangoStore.getState().connection.client
|
||||
|
||||
mangoClient.updateRecentBlockhash(blockhashTimesCopy).then(() => {
|
||||
setMangoStore((state) => {
|
||||
state.connection.client = mangoClient
|
||||
state.connection.blockhashTimes = blockhashTimesCopy
|
||||
})
|
||||
})
|
||||
}, 10 * SECONDS)
|
||||
|
||||
useEffect(() => {
|
||||
actions.loadMarketFills()
|
||||
}, [selectedMarket])
|
||||
|
|
|
@ -257,7 +257,7 @@ const useMangoStore = create<
|
|||
txid: txid,
|
||||
})
|
||||
},
|
||||
maxStoredBlockhashes: CLUSTER === 'devnet' ? 1 : 3,
|
||||
blockhashCommitment: 'finalized',
|
||||
})
|
||||
return {
|
||||
marketsInfo: [],
|
||||
|
|
Loading…
Reference in New Issue