cleanup
This commit is contained in:
@@ -89,23 +89,31 @@ export function Wizard({
|
|||||||
} = useProfileQuery({did: currentAccount?.did})
|
} = useProfileQuery({did: currentAccount?.did})
|
||||||
|
|
||||||
if (
|
if (
|
||||||
name &&
|
(name &&
|
||||||
rkey &&
|
rkey &&
|
||||||
(!starterPack || (starterPack && listUri && !listItems))
|
(!starterPack || (starterPack && listUri && !listItems))) ||
|
||||||
|
!profile
|
||||||
) {
|
) {
|
||||||
return (
|
return (
|
||||||
<ListMaybePlaceholder
|
<ListMaybePlaceholder
|
||||||
isLoading={isLoadingDid || isLoadingStarterPack || isLoadingProfiles}
|
isLoading={
|
||||||
isError={isErrorDid || isErrorStarterPack || isErrorProfiles}
|
isLoadingDid ||
|
||||||
|
isLoadingStarterPack ||
|
||||||
|
isLoadingProfiles ||
|
||||||
|
isLoadingProfile
|
||||||
|
}
|
||||||
|
isError={
|
||||||
|
isErrorDid || isErrorStarterPack || isErrorProfiles || isErrorProfile
|
||||||
|
}
|
||||||
errorMessage={_(msg`Could not find that starter pack`)}
|
errorMessage={_(msg`Could not find that starter pack`)}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
} else if (!profile) {
|
} else if (name && rkey && starterPack?.creator.did !== currentAccount?.did) {
|
||||||
return (
|
return (
|
||||||
<ListMaybePlaceholder
|
<ListMaybePlaceholder
|
||||||
isLoading={isLoadingProfile}
|
isLoading={false}
|
||||||
isError={isErrorProfile}
|
isError={true}
|
||||||
errorMessage={_(msg`Could not load your profile`)}
|
errorMessage={_(msg`Could not find that starter pack`)}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user