Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
inukshuk committed Oct 22, 2020
1 parent 5462e15 commit 2fa95c1
Showing 1 changed file with 14 additions and 13 deletions.
27 changes: 14 additions & 13 deletions lib/run.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,21 @@ exports.builder = yargs => {
const original = obj[prop]

return (typeof original !== 'function')
? original : (...args) => {
let result

switch (prop) {
case 'check':
case 'middleware':
result = obj
break
default:
result = original.apply(obj, args)
? original
: (...args) => {
let result

switch (prop) {
case 'check':
case 'middleware':
result = obj
break
default:
result = original.apply(obj, args)
}

return (result === obj) ? proxy : result
}

return (result === obj) ? proxy : result
}
}
}))

Expand Down

0 comments on commit 2fa95c1

Please sign in to comment.