Merge pull request #17136 from supabase/fix/allow-local-offline

fix(self-hosted): allow offline
This commit is contained in:
Joshen Lim authored and GitHub committed 2023-09-05 10:25:21 +08:00
commit a476f79bb7
1 file changed
+8 -1
+8 -1
View File
@@ -1,6 +1,13 @@
import { QueryClient } from '@tanstack/react-query'
import { QueryClient, onlineManager } from '@tanstack/react-query'
import { IS_PLATFORM } from 'lib/constants'
import { useState } from 'react'
// When running locally we don't need the internet
// so we can pretend we're online all the time
if (!IS_PLATFORM) {
onlineManager.setOnline(true)
}
let queryClient: QueryClient | undefined
export function getQueryClient() {