Skip to content

Commit

Permalink
use more universal delay validation
Browse files Browse the repository at this point in the history
  • Loading branch information
eritikass committed Apr 11, 2018
1 parent 62809a2 commit 14881d7
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions packages/jest-util/src/fake_timers.js
Original file line number Diff line number Diff line change
Expand Up @@ -486,9 +486,7 @@ export default class FakeTimers<TimerRef> {
return null;
}

if (delay == null || Number.isNaN(delay) || !Number.isFinite(delay)) {
delay = 0;
}
delay = Number(delay) | 0;

const args = [];
for (let ii = 2, ll = arguments.length; ii < ll; ii++) {
Expand Down

0 comments on commit 14881d7

Please sign in to comment.