s/setupRoutes/NewRouter

This commit is contained in:
Jimmy Zelinskie
2014-07-16 04:40:51 -04:00
parent a614f42a94
commit 65bd11f636
2 changed files with 3 additions and 3 deletions

View File

@@ -62,7 +62,7 @@ func makeHandler(handler ResponseHandler) httprouter.Handle {
}
}
func setupRoutes(t *Tracker, cfg *config.Config) *httprouter.Router {
func NewRouter(t *Tracker, cfg *config.Config) *httprouter.Router {
r := httprouter.New()
if cfg.Private {
@@ -94,7 +94,7 @@ func Serve(cfg *config.Config) {
glog.Fatal("New: ", err)
}
graceful.Run(cfg.Addr, cfg.RequestTimeout.Duration, setupRoutes(t, cfg))
graceful.Run(cfg.Addr, cfg.RequestTimeout.Duration, NewRouter(t, cfg))
}
func fail(w http.ResponseWriter, r *http.Request, err error) {