Skip to content

Commit

Permalink
Merge pull request #53 from karl/feature-check-process
Browse files Browse the repository at this point in the history
Check for existence of `process` before using it
  • Loading branch information
fatso83 committed Apr 19, 2016
2 parents d99c698 + 8b192f1 commit 3281d41
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/lolex-src.js
Original file line number Diff line number Diff line change
Expand Up @@ -405,9 +405,12 @@
setInterval: setInterval,
clearInterval: clearInterval,
Date: Date,
hrtime: global.process.hrtime
};

if (hrtimePresent) {
timers.hrtime = global.process.hrtime;
}

var keys = Object.keys || function (obj) {
var ks = [],
key;
Expand Down

0 comments on commit 3281d41

Please sign in to comment.