Stop setting up the web server when doing an update...

This commit is contained in:
A. Svensson 2016-02-20 17:54:21 +01:00
parent 642e5227eb
commit 9043b8b10d

View File

@ -11,7 +11,10 @@ import (
func (i *Instance) Init() {
InitSchema(i.DB)
}
func (i *Instance) Serve(addr string) error {
i.addr = addr
if i.Debug == false {
gin.SetMode(gin.ReleaseMode)
}
@ -45,10 +48,7 @@ func (i *Instance) Init() {
//i.router.GET("/stats", page_stats)
//i.router.GET("/about", page_about)
}
func (i *Instance) Serve(addr string) error {
i.addr = addr
return i.router.Run(i.addr)
}