Merge pull request #1115 from tianon/fix-auth-servehttp-comment

Update "type auth.Challenge" comment example code
This commit is contained in:
Stephen Day 2015-10-21 12:56:14 -07:00
commit e6bb0aa7c0

View file

@ -21,7 +21,9 @@
// if ctx, err := accessController.Authorized(ctx, access); err != nil { // if ctx, err := accessController.Authorized(ctx, access); err != nil {
// if challenge, ok := err.(auth.Challenge) { // if challenge, ok := err.(auth.Challenge) {
// // Let the challenge write the response. // // Let the challenge write the response.
// challenge.ServeHTTP(w, r) // challenge.SetHeaders(w)
// w.WriteHeader(http.StatusUnauthorized)
// return
// } else { // } else {
// // Some other error. // // Some other error.
// } // }