Fixed mistakes

This commit is contained in:
FM1337
2017-06-22 12:03:43 -03:00
parent ad7bc381ac
commit f6e5b6da08
4 changed files with 22 additions and 21 deletions

View File

@ -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))
}