mirror of
https://github.com/ultrasn0w/huso.git
synced 2025-12-13 17:29:54 +01:00
Charts V1
This commit is contained in:
11
ober.go
11
ober.go
@@ -9,6 +9,7 @@ import (
|
||||
"time"
|
||||
|
||||
"github.com/fasthttp/router"
|
||||
"github.com/gookit/color"
|
||||
"github.com/valyala/fasthttp"
|
||||
"github.com/xujiajun/nutsdb"
|
||||
)
|
||||
@@ -46,11 +47,15 @@ func Start(ctx *fasthttp.RequestCtx) {
|
||||
|
||||
oracles, err := MmReadOracle()
|
||||
if err != nil {
|
||||
addErrorToCtx(ctx, err)
|
||||
return
|
||||
color.Errorln(err.Error())
|
||||
}
|
||||
|
||||
WriteIndex(ctx, season, oracles, logOut.String())
|
||||
charts, err := BuildMovieCharts()
|
||||
if err != nil {
|
||||
color.Errorln(err.Error())
|
||||
}
|
||||
|
||||
WriteIndex(ctx, season, oracles, charts, logOut.String())
|
||||
|
||||
ctx.SetContentType("text/html; charset=utf-8")
|
||||
ctx.SetStatusCode(fasthttp.StatusOK)
|
||||
|
||||
Reference in New Issue
Block a user