fix lightning when loading session

This commit is contained in:
keyan 2021-09-24 18:51:07 -05:00
parent 8c5832c3e6
commit 4ba0bcd416
1 changed files with 4 additions and 5 deletions

View File

@ -33,11 +33,7 @@ export default function Header () {
const [session, loading] = useSession()
const Corner = () => {
if (loading && !me) {
return null
}
if (session) {
if (me) {
return (
<div className='d-flex align-items-center'>
<Head>
@ -101,6 +97,9 @@ export default function Header () {
</div>
)
} else {
if (loading || session) {
return null
}
const strike = useLightning()
useEffect(() => {
setTimeout(strike, randInRange(3000, 10000))