🔧 Custom cache duration

This commit is contained in:
微凉
2021-12-30 20:42:37 +08:00
parent cf2506901f
commit 582f7bbfee
3 changed files with 29 additions and 10 deletions

View File

@ -48,8 +48,8 @@ func main() {
base := fmt.Sprintf("%s:%d", conf.Conf.Address, conf.Conf.Port)
log.Infof("start server @ %s", base)
var err error
if conf.Conf.Https {
err = r.RunTLS(base, conf.Conf.CertFile, conf.Conf.KeyFile)
if conf.Conf.Scheme.Https {
err = r.RunTLS(base, conf.Conf.Scheme.CertFile, conf.Conf.Scheme.KeyFile)
} else {
err = r.Run(base)
}