mirror of
https://github.com/kataras/iris.git
synced 2025-03-14 08:16:28 +01:00
Merge pull request #758 from itcrow/master
Fix issue #757 Former-commit-id: d3734c3acd128aef717506258bab0b1d7ac501ef
This commit is contained in:
commit
e3563cff59
2
iris.go
2
iris.go
|
@ -470,7 +470,7 @@ type Runner func(*Application) error
|
||||||
func Listener(l net.Listener, hostConfigs ...host.Configurator) Runner {
|
func Listener(l net.Listener, hostConfigs ...host.Configurator) Runner {
|
||||||
return func(app *Application) error {
|
return func(app *Application) error {
|
||||||
app.config.vhost = netutil.ResolveVHost(l.Addr().String())
|
app.config.vhost = netutil.ResolveVHost(l.Addr().String())
|
||||||
return app.NewHost(new(http.Server)).
|
return app.NewHost(&http.Server{Addr: l.Addr().String()}).
|
||||||
Configure(hostConfigs...).
|
Configure(hostConfigs...).
|
||||||
Serve(l)
|
Serve(l)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user