profile-hotfix
This commit is contained in:
parent
9ba7bfada8
commit
1a2d197e0c
|
@ -66,7 +66,7 @@ export const AuthorView = (props: Props) => {
|
||||||
const { authors, profile, topics } = appdata
|
const { authors, profile, topics } = appdata
|
||||||
setFollowers(myFollowers)
|
setFollowers(myFollowers)
|
||||||
setAuthor(profile)
|
setAuthor(profile)
|
||||||
setFollowing([...authors, ...topics])
|
setFollowing([...(authors || []), ...(topics || [])])
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
@ -75,6 +75,7 @@ export const AuthorView = (props: Props) => {
|
||||||
const bioWrapperRef: { current: HTMLDivElement } = { current: null }
|
const bioWrapperRef: { current: HTMLDivElement } = { current: null }
|
||||||
|
|
||||||
const fetchData = async (slug: string) => {
|
const fetchData = async (slug: string) => {
|
||||||
|
if (author()?.stat.followers || author()?.stat.followers === (followers() || [])?.length) return
|
||||||
try {
|
try {
|
||||||
const [subscriptionsResult, followersResult, authorResult] = await Promise.all([
|
const [subscriptionsResult, followersResult, authorResult] = await Promise.all([
|
||||||
apiClient.getAuthorFollows({ slug }),
|
apiClient.getAuthorFollows({ slug }),
|
||||||
|
@ -215,7 +216,7 @@ export const AuthorView = (props: Props) => {
|
||||||
slug: props.authorSlug,
|
slug: props.authorSlug,
|
||||||
})}
|
})}
|
||||||
>
|
>
|
||||||
{t('Profile')}
|
{t('About')}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user