Skip to content
This repository has been archived by the owner on Aug 10, 2023. It is now read-only.

Fixes both #100 and #101 #102

Merged
merged 6 commits into from
Apr 14, 2017
Merged

Fixes both #100 and #101 #102

merged 6 commits into from
Apr 14, 2017

Conversation

yunong
Copy link
Member

@yunong yunong commented Apr 14, 2017

Fixes both #100 and #101
#100 Adding bodyParser plugin twice no longer blackholes requests.
#101 Fix failing test by adding metrics.inflightRequests as a proxy to unfinishedRequests

@@ -39,6 +39,13 @@ function bodyParser(options) {
var parseFieldedText = fieldedTextParser(opts);

function parseBody(req, res, next) {
// #100 don't parse the body again if we've read it once
if (req._parsedBody) {
next();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't we have a lint rule to return on next? return next()

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We do, but this is also scope creep as I'm just being consistent with the rest of the repo. Happy to discuss in a separate issue.

@yunong
Copy link
Member Author

yunong commented Apr 14, 2017

@DonutEspresso @rajatkumar any other concerns?

@yunong yunong merged commit 30354f8 into master Apr 14, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants