htpasswd file relative to repo

This commit is contained in:
Chapuis Bertil 2015-09-07 15:32:38 +02:00
parent 738e78c439
commit ff5e60135c
2 changed files with 5 additions and 3 deletions

View file

@ -22,7 +22,7 @@ func (router Router) ServeHTTP(w http.ResponseWriter, r *http.Request) {
log.Printf("%s %s", m, u)
if err := Authorize(r); err == nil {
if err := Authorize(r, &router.Context); err == nil {
if handler := RestAPI(m, u); handler != nil {
handler(w, r, &router.Context)
} else {