Skip to content

Commit

Permalink
Merge pull request #729 from lightblade/master
Browse files Browse the repository at this point in the history
websocket needs to respect `options.secure` too
  • Loading branch information
jcrugzz committed Nov 4, 2014
2 parents 60bd697 + d1eabcc commit 57329b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/http-proxy/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ common.setupOutgoing = function(outgoing, options, req, forward) {
extend(outgoing.headers, options.headers);
}

if (options[forward || 'target'].protocol == 'https:') {
if (~['https:', 'wss:'].indexOf(options[forward || 'target'].protocol)) {
outgoing.rejectUnauthorized = (typeof options.secure === "undefined") ? true : options.secure;
}

Expand Down

0 comments on commit 57329b6

Please sign in to comment.