Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why doesn't the http.ResposeWriter implement http.Flush #8

Closed
lucat1 opened this issue Dec 2, 2019 · 1 comment
Closed

Why doesn't the http.ResposeWriter implement http.Flush #8

lucat1 opened this issue Dec 2, 2019 · 1 comment

Comments

@lucat1
Copy link

lucat1 commented Dec 2, 2019

Given this test function:

func test(w http.ResponseWriter, r *http.Request) {
	_, ok := w.(http.Flusher)
	fmt.Println(ok)
}

This returns true:

func main() {
	http.ListenAndServe(":8080", http.HandlerFunc(test))
}

This returns false:

func main() {
	mux := muxie.NewMux()
	mux.HandleFunc("/*path", test)
	http.ListenAndServe(":8080", mux)
}

Is there any reason why the http.RequestWriter does not implement http.Flusher? I absolutely need this feature for my usage of the router

@kataras

@kataras kataras closed this as completed in ee2fdec Dec 5, 2019
@kataras
Copy link
Owner

kataras commented Dec 5, 2019

Hello @lucat1,

Sorry for the delay and the issue, it has been resolved. Please upgrade to v1.0.8.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants