tsc-passed
This commit is contained in:
parent
acbe96a830
commit
7af3f1d405
|
@ -29,12 +29,9 @@ export const ProfileSubscriptions = () => {
|
|||
const fetchSubscriptions = async () => {
|
||||
try {
|
||||
const slug = author()?.slug
|
||||
const [getAuthors, getTopics] = await Promise.all([
|
||||
apiClient.getAuthorFollowingAuthors({ slug }),
|
||||
apiClient.getAuthorFollowingTopics({ slug }),
|
||||
])
|
||||
setFollowing([...getAuthors, ...getTopics])
|
||||
setFiltered([...getAuthors, ...getTopics])
|
||||
const authorFollows = await apiClient.getAuthorFollows({ slug })
|
||||
setFollowing([...authorFollows['authors']])
|
||||
setFiltered([...authorFollows['authors'], ...authorFollows['topics']])
|
||||
} catch (error) {
|
||||
console.error('[fetchSubscriptions] :', error)
|
||||
throw error
|
||||
|
|
|
@ -26,7 +26,6 @@ export function useFollowing() {
|
|||
const EMPTY_SUBSCRIPTIONS: AuthorFollows = {
|
||||
topics: [],
|
||||
authors: [],
|
||||
shouts: [],
|
||||
communities: [],
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user