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

Passing http.ResponseWriter, *http.Request and martini.Params to a handler #317

Closed
brknstrngz opened this Issue Nov 9, 2014 · 1 comment

Comments

Projects
None yet
1 participant
@brknstrngz

brknstrngz commented Nov 9, 2014

Hi,

I haven't been able to figure out if this was possible in the first place (the docs say it should be and Martini would resolve the dependecies) or what the proper order was. I need to invoke a handler using a regexp+capture group match and have access to both the request and response inside the handler (that does not return string, I need to be able to send responses back through the response reference).

Thanks for any hints!

@brknstrngz

This comment has been minimized.

brknstrngz commented Nov 9, 2014

Replying to myself here. It seems that as long as the handler takes a martini.Params, a http.ResponseWriter and a *http.Request and returns void, the above is possible.

@brknstrngz brknstrngz closed this Nov 9, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment