Skip to content

Commit 11526a9

Browse files
authored
🔧 fix profile search unknow page for 1s (#135)
1 parent 55f940d commit 11526a9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/pages/profile/[email]/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ const Profile = () => {
5353
const router = useRouter();
5454
const { t } = useContext(i18nContext);
5555
const { context, email: userEmail } = router.query;
56-
const { data, error } = useQuery<GetUserAgencyAndAllAgenciesResult>(
56+
const { data, error, loading } = useQuery<GetUserAgencyAndAllAgenciesResult>(
5757
USER_INFOS,
5858
{
5959
variables: { email: userEmail },
@@ -81,7 +81,7 @@ const Profile = () => {
8181

8282
return (
8383
<div>
84-
{data?.User?.length > 0 && !error ? (
84+
{(data?.User?.length > 0 && !error) || loading ? (
8585
<CommonPage page={"profile"} faded={false} context={context}>
8686
<div className="flex flex-row justify-center mt-4 mb-20">
8787
<div className="flex flex-col justify-center max-w-screen-md w-full p-4">

0 commit comments

Comments
 (0)