19 lines
252 B
Go
Raw Normal View History

2018-04-16 13:48:54 +00:00
package amvs
import (
"sort"
"github.com/aerogo/aero"
)
// Latest AMVs.
2019-06-01 04:55:49 +00:00
func Latest(ctx aero.Context) error {
2018-04-16 13:48:54 +00:00
amvs := fetchAll()
sort.Slice(amvs, func(i, j int) bool {
return amvs[i].Created > amvs[j].Created
})
return render(ctx, amvs)
}