Skip to content
Snippets Groups Projects
Commit 05d0bc8d authored by Aksel Baardsen's avatar Aksel Baardsen
Browse files

commented main.go

parent 94b18f48
No related branches found
No related tags found
No related merge requests found
......@@ -15,6 +15,7 @@ func main() {
port = "5000"
}
// creating a subrouter with a fixed path
c := r.PathPrefix("/conservation/v1").Methods("GET").Subrouter()
// two handlerpaths makes sure that the caller does not HAVE to specify limit
......@@ -31,6 +32,7 @@ func main() {
c.Path("/diag/").
HandlerFunc(handler.Dhandler)
// makes sure that the router r handles all http-requests
http.Handle("/", r)
log.Fatal(http.ListenAndServe(":"+port, nil))
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment