Skip to content

Commit

Permalink
Merge pull request #104 from senecajs/fix-confusing-code-in-tests
Browse files Browse the repository at this point in the history
Resolve confusion in test code
  • Loading branch information
rjrodger committed Jun 14, 2021
2 parents 319bed2 + 4663e17 commit 93d724d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions test/mem.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -1186,13 +1186,14 @@ describe('additional mem-store tests', () => {
}
})()

const is_log = null == log || !('level_name' in log)
const is_log = null != log && 'level_name' in log

if (is_log) {
return writeToStdout.call(process.stdout, out)
out_logs.push(log)
return
}

out_logs.push(log)
return writeToStdout.call(process.stdout, out)
}
}

Expand Down

0 comments on commit 93d724d

Please sign in to comment.