1
0
mirror of https://github.com/oceanprotocol/market.git synced 2024-12-02 05:57:29 +01:00

fix Graph sync status randomly failing (#522)

Co-authored-by: Norbi <katunanorbert@gmai.com>
This commit is contained in:
Norbi 2021-04-15 13:43:12 +03:00 committed by GitHub
parent 2826df8287
commit 85a956a8f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -112,11 +112,13 @@ function Web3Provider({ children }: { children: ReactNode }): ReactElement {
const [block, setBlock] = useState<number>()
const [isTestnet, setIsTestnet] = useState<boolean>()
const [accountId, setAccountId] = useState<string>()
const [web3Loading, setWeb3Loading] = useState<boolean>()
const [web3Loading, setWeb3Loading] = useState<boolean>(true)
const connect = useCallback(async () => {
if (!web3Modal) return
if (!web3Modal) {
setWeb3Loading(false)
return
}
try {
setWeb3Loading(true)
Logger.log('[web3] Connecting Web3...')