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

#48 Use req.params instead of body and query in lookup #55

Closed
wants to merge 1 commit into from

Conversation

krampstudio
Copy link

To fix issue #48

@jaredhanson
Copy link
Owner

Thanks. req.params is typically created by express (and I'm assuming restify). For anyone just using Connect's bodyParser and query middleware, it won't be available and this will break that. Do you have a solution in mind for that? Just check all three places?

Also, can you point me to any docs as to what properties restify sets up on the req and res, prior to dispatching to the application?

@jaredhanson
Copy link
Owner

Rejected due to reasons detailed above. Closing.

@jaredhanson jaredhanson closed this Mar 6, 2014
@johnmave126
Copy link

Just a quick note if anyone else encounter the same problem
https://github.com/mcavage/node-restify/blob/master/lib/plugins/json_body_parser.js#L42
https://github.com/mcavage/node-restify/blob/master/lib/plugins/form_body_parser.js#L43

Remember to use
server.use(restify.bodyParser({mapParams: false});
to parse params into req.body to comply with passport-local

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

Successfully merging this pull request may close these issues.

3 participants