Fixed mistakes
This commit is contained in:
@ -27,6 +27,7 @@ func Profile(ctx *aero.Context, viewUser *arn.User) string {
|
||||
var threads []*arn.Thread
|
||||
var animeList *arn.AnimeList
|
||||
var posts []*arn.Post
|
||||
|
||||
aero.Parallel(func() {
|
||||
user = utils.GetUser(ctx)
|
||||
}, func() {
|
||||
@ -39,13 +40,14 @@ func Profile(ctx *aero.Context, viewUser *arn.User) string {
|
||||
if len(threads) > maxPosts {
|
||||
threads = threads[:maxPosts]
|
||||
}
|
||||
},
|
||||
func() {
|
||||
posts = viewUser.Posts()
|
||||
if len(posts) > maxPosts {
|
||||
posts = posts[:maxPosts]
|
||||
}
|
||||
})
|
||||
}, func() {
|
||||
posts = viewUser.Posts()
|
||||
|
||||
if len(posts) > maxPosts {
|
||||
posts = posts[:maxPosts]
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
return ctx.HTML(components.Profile(viewUser, user, animeList, threads, posts))
|
||||
}
|
||||
|
Reference in New Issue
Block a user