-
Notifications
You must be signed in to change notification settings - Fork 38
Open
Description
Because it doesn't call setImmediate before calling the callback function it is possible to unleash zalgo. e.g.
var delay = thunkify(function (time, callback) {
setTimeout(callback, time);
});
var result = delay(100);
setTimeout(function () {
console.log('a');
result(function () {
console.log('c');
});
console.log('b');
}, 500);Expected:
a
b
c
Actual:
a
c
b
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels