fmt
This commit is contained in:
parent
bd4fedc6c7
commit
f7c33c167a
|
@ -64,12 +64,12 @@ export const AuthorView = (props: Props) => {
|
||||||
})
|
})
|
||||||
|
|
||||||
createEffect(async () => {
|
createEffect(async () => {
|
||||||
if(Object.keys(authorEntities()).includes(props.authorSlug) && !author()?.id) {
|
if (Object.keys(authorEntities()).includes(props.authorSlug) && !author()?.id) {
|
||||||
// use preloaded author
|
// use preloaded author
|
||||||
const a = authorEntities()[props.authorSlug]
|
const a = authorEntities()[props.authorSlug]
|
||||||
setAuthor(a)
|
setAuthor(a)
|
||||||
console.debug('[AuthorView] preloaded author:', a)
|
console.debug('[AuthorView] preloaded author:', a)
|
||||||
} else if(props.authorSlug || (author()?.id && !author().stat)) {
|
} else if (props.authorSlug || (author()?.id && !author().stat)) {
|
||||||
// load author
|
// load author
|
||||||
const a = await loadAuthor({ slug: props.authorSlug, author_id: author()?.id })
|
const a = await loadAuthor({ slug: props.authorSlug, author_id: author()?.id })
|
||||||
setAuthor(a)
|
setAuthor(a)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user