More session improvements (#2129)

* More session improvements

* Drop resume session retries from 3 to 1

---------

Co-authored-by: Paul Frazee <pfrazee@gmail.com>
This commit is contained in:
Eric Bailey 2023-12-07 12:25:55 -06:00 committed by GitHub
parent a0b9fd799b
commit 261a935747
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 67 additions and 53 deletions

View file

@ -30,7 +30,7 @@ import {Provider as UnreadNotifsProvider} from 'state/queries/notifications/unre
import * as persisted from '#/state/persisted'
function InnerApp() {
const {isInitialLoad, currentAccount} = useSession()
const {currentAccount} = useSession()
const {resumeSession} = useSessionApi()
const colorMode = useColorMode()
@ -40,16 +40,6 @@ function InnerApp() {
resumeSession(account)
}, [resumeSession])
// show nothing prior to init
if (isInitialLoad) {
// TODO add a loading state
return null
}
/*
* Session and initial state should be loaded prior to rendering below.
*/
return (
<React.Fragment
// Resets the entire tree below when it changes: