mirror of
https://github.com/lemeow125/StudE-Frontend.git
synced 2024-11-16 22:09:26 +08:00
Possible fix to race conditions between queries in homepage which resulted in laggy rerenders of map
This commit is contained in:
parent
bd42b5418e
commit
88d8ce05b8
1 changed files with 8 additions and 6 deletions
|
@ -381,12 +381,14 @@ export default function Home() {
|
|||
</>
|
||||
);
|
||||
} else if (
|
||||
(StudentStatusQuery.isFetching && studying) ||
|
||||
StudentStatusListQuery.isFetching ||
|
||||
StudyGroupQuery.isFetching ||
|
||||
(StudentStatusQuery.isFetching && !studying) ||
|
||||
StudentStatusListGlobalQuery.isFetching ||
|
||||
StudyGroupGlobalQuery.isFetching
|
||||
(!StudentStatusQuery.isSuccess &&
|
||||
studying &&
|
||||
!StudentStatusListQuery.isSuccess &&
|
||||
!StudyGroupQuery.isSuccess &&
|
||||
!StudentStatusQuery.isSuccess) ||
|
||||
(!studying &&
|
||||
!StudentStatusListGlobalQuery.isSuccess &&
|
||||
!StudyGroupGlobalQuery.isSuccess)
|
||||
) {
|
||||
return (
|
||||
<>
|
||||
|
|
Loading…
Reference in a new issue