Browse Source

fix typos

tags/v0.9.0
jimzhan 9 years ago
parent
commit
959570a4c5
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      README.md

+ 2
- 2
README.md View File

app.Use(func(next http.Handler) http.Handler { app.Use(func(next http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
log.Printf("Custom Middleware Module Started") log.Printf("Custom Middleware Module Started")
next.ServeHTTP(writer, request)
next.ServeHTTP(w, r)
log.Printf("Custom Middleware Module Ended") log.Printf("Custom Middleware Module Ended")
}) })
}) })
user.Use(func(next http.Handler) http.Handler { user.Use(func(next http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
log.Printf("this is a protected page") log.Printf("this is a protected page")
next.ServeHTTP(writer, request)
next.ServeHTTP(w, r)
}) })
}) })
``` ```

Loading…
Cancel
Save