Skip to content

Commit

Permalink
style: prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
gr2m committed Nov 8, 2021
1 parent b9e24e4 commit ed5ce6c
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion lib/back.js
Expand Up @@ -263,7 +263,7 @@ function removeFixture(fixture, options) {
}

if (fixture && fixtureExists(fixture)) {
fs.rmSync ? fs.rmSync(fixture) : fs.unlinkSync(fixture);
fs.rmSync ? fs.rmSync(fixture) : fs.unlinkSync(fixture)
}
context.isLoaded = false
return context
Expand Down
12 changes: 7 additions & 5 deletions lib/common.js
Expand Up @@ -651,11 +651,13 @@ const timeouts = []
const intervals = []
const immediates = []

const wrapTimer = (timer, ids) => (...args) => {
const id = timer(...args)
ids.push(id)
return id
}
const wrapTimer =
(timer, ids) =>
(...args) => {
const id = timer(...args)
ids.push(id)
return id
}

const setTimeout = wrapTimer(timers.setTimeout, timeouts)
const setInterval = wrapTimer(timers.setInterval, intervals)
Expand Down
5 changes: 2 additions & 3 deletions lib/intercepted_request_router.js
Expand Up @@ -279,9 +279,8 @@ class InterceptedRequestRouter {
const requestBodyBuffer = Buffer.concat(this.requestBodyBuffers)
// When request body is a binary buffer we internally use in its hexadecimal
// representation.
const requestBodyIsUtf8Representable = common.isUtf8Representable(
requestBodyBuffer
)
const requestBodyIsUtf8Representable =
common.isUtf8Representable(requestBodyBuffer)
const requestBodyString = requestBodyBuffer.toString(
requestBodyIsUtf8Representable ? 'utf8' : 'hex'
)
Expand Down

0 comments on commit ed5ce6c

Please sign in to comment.