Skip to content

Commit

Permalink
Allow internal nextTick utility to use microtasks when possible.
Browse files Browse the repository at this point in the history
  • Loading branch information
rwjblue committed Oct 8, 2018
1 parent 03373db commit ba418a1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion addon-test-support/@ember/test-helpers/-utils.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { Promise } from 'rsvp';

export const nextTick = setTimeout;
export const nextTick =
typeof Promise === 'undefined' ? setTimeout : cb => Promise.resolve().then(cb);
export const futureTick = setTimeout;

/**
Expand Down

0 comments on commit ba418a1

Please sign in to comment.