parent
59f436052e
commit
ae019e4dc3
6
app.go
6
app.go
|
@ -249,7 +249,11 @@ func Serve() {
|
||||||
http.Handle("/", r)
|
http.Handle("/", r)
|
||||||
log.Info("Serving on http://localhost:%d\n", app.cfg.Server.Port)
|
log.Info("Serving on http://localhost:%d\n", app.cfg.Server.Port)
|
||||||
log.Info("---")
|
log.Info("---")
|
||||||
http.ListenAndServe(fmt.Sprintf(":%d", app.cfg.Server.Port), nil)
|
err = http.ListenAndServe(fmt.Sprintf(":%d", app.cfg.Server.Port), nil)
|
||||||
|
if err != nil {
|
||||||
|
log.Error("Unable to start: %v", err)
|
||||||
|
os.Exit(1)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func connectToDatabase(app *app) {
|
func connectToDatabase(app *app) {
|
||||||
|
|
Loading…
Reference in New Issue