Skip to content
This repository has been archived by the owner on Apr 24, 2019. It is now read-only.

added preserveHost option #30

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

added preserveHost option #30

wants to merge 3 commits into from

Conversation

ilyabo
Copy link

@ilyabo ilyabo commented May 2, 2016

In some situations a proxy needs to preserve the original host. It should be possible to do it via options analogous to this apache proxy directive.

@coveralls
Copy link

coveralls commented May 2, 2016

Coverage Status

Coverage increased (+0.05%) to 96.825% when pulling 4d099e3 on ilyabo:master into 3dc98e4 on popomore:master.

@coveralls
Copy link

coveralls commented May 2, 2016

Coverage Status

Coverage increased (+0.05%) to 96.825% when pulling 9604135 on ilyabo:master into 3dc98e4 on popomore:master.

…ns as a function has access to the original host
@coveralls
Copy link

coveralls commented May 9, 2016

Coverage Status

Coverage increased (+0.05%) to 96.825% when pulling d329327 on ilyabo:master into 3dc98e4 on popomore:master.

@@ -34,12 +34,10 @@ module.exports = function(options) {
headers: this.header,
encoding: null,
method: this.method,
body: parsedBody
body: parsedBody,
followRedirect: options.followRedirect || true
Copy link
Owner

Choose a reason for hiding this comment

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

followRedirect is true by default, the condition can be options.followRedirect !== false

@popomore
Copy link
Owner

popomore commented Feb 2, 2017

Can you add a testcase and document about these two options?

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.

3 participants