func main() { models.Init() r := mux.NewRouter() http.Handle("/", session.Middleware(r)) s := r.PathPrefix("/api").Subrouter() api.Route(s) r.PathPrefix("/").Handler(http.FileServer(http.Dir("public/"))) http.ListenAndServe(":8000", nil) }
func init() { models.Init() }
func init() { models.Init() mTransaction = mux.NewRouter() s := mTransaction.PathPrefix("/api").Subrouter() api.Route(s) }
func init() { models.Init() m = mux.NewRouter() s := m.PathPrefix("/api").Subrouter() api.Route(s) }