Skip to content

Commit

Permalink
fix lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
dimapaloskin committed Apr 13, 2017
1 parent af1022e commit c53292a
Show file tree
Hide file tree
Showing 2 changed files with 240 additions and 251 deletions.
5 changes: 3 additions & 2 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ module.exports = opts => {
(!opts.location || (opts.location.test(req.url)))
) {
try {
for (let link of opts.chain) {
for (const link of opts.chain) {
let bodyToSend = body;
if (link.transformRequestBody) {
bodyToSend = link.transformRequestBody(bodyToSend);
Expand All @@ -48,6 +48,7 @@ module.exports = opts => {
}
}

// eslint-disable-next-line no-await-in-loop
const result = await doRequest(req, (link.sendOriginalBody ? originalBody : bodyToSend), link);
const allowedStatuses = link.allowedStatuses || [200];

Expand Down Expand Up @@ -81,7 +82,7 @@ module.exports = opts => {

const originalRequest = await doRequest(req, body, { target: full.format(), isOriginal: true });

for (let key in originalRequest.headers) {
for (const key in originalRequest.headers) {
if ({}.hasOwnProperty.call(originalRequest.headers, key)) {
res.setHeader(key, originalRequest.headers[key]);
}
Expand Down
Loading

0 comments on commit c53292a

Please sign in to comment.