Improved explore page

This commit is contained in:
2017-11-12 11:18:16 +01:00
parent 54193978fe
commit d17376e5a7
8 changed files with 34 additions and 38 deletions

View File

@ -4,10 +4,12 @@ import (
"github.com/aerogo/aero"
"github.com/animenotifier/arn"
"github.com/animenotifier/notify.moe/components"
"github.com/animenotifier/notify.moe/utils"
)
// Get ...
func Get(ctx *aero.Context) string {
user := utils.GetUser(ctx)
genreName := ctx.Get("name")
genre, err := arn.GetGenre(genreName)
@ -15,5 +17,5 @@ func Get(ctx *aero.Context) string {
return ctx.Error(404, "Genre not found", err)
}
return ctx.HTML(components.Genre(genre))
return ctx.HTML(components.Genre(genre, user))
}