forked from coolaj86/goldilocks.js
made `status` optional for redirection
This commit is contained in:
parent
d16f857fca
commit
474f9766d8
|
@ -165,7 +165,7 @@ module.exports.create = function (deps, conf, greenlockMiddleware) {
|
||||||
match.slice(1).forEach(function (globMatch, index) {
|
match.slice(1).forEach(function (globMatch, index) {
|
||||||
to = to.replace(':'+(index+1), globMatch);
|
to = to.replace(':'+(index+1), globMatch);
|
||||||
});
|
});
|
||||||
res.writeHead(mod.status, { 'Location': to });
|
res.writeHead(mod.status || 301, { 'Location': to });
|
||||||
res.end();
|
res.end();
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue