diff --git a/Host.md b/Host.md index e966c0f..8d32694 100644 --- a/Host.md +++ b/Host.md @@ -136,7 +136,8 @@ There may be times that you want something very special to listen on, which is n // the responsibility of starting up a listener is up to you with this way, // for the sake of simplicity we will use the // ListenAndServe function of the `net/http` package. -app.Run(iris.Raw(&http.Server{Addr:":8080"}).ListenAndServe) +srv := &http.Server{Addr:":8080"} +app.Run(iris.Raw(srv.ListenAndServe)) ``` ## Host configurators