MCPcopy Index your code
hub / github.com/prototypejs/prototype / handler

Function handler

test/unit/static/js/test_helpers.js:57–66  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

55 // is far more readable within tests.
56 function wait(duration, done, fn) {
57 var handler = function () {
58 try {
59 fn();
60 } catch (e) {
61 // Instead of relying on window.onerror to detect an error was
62 // thrown (which is problematic in IE6-7), we invoke the callback
63 // with an error the way Mocha expects.
64 return done(e);
65 }
66 };
67 return setTimeout(handler, duration);
68 }
69 window.wait = wait;

Callers

nothing calls this directly

Calls 1

doneFunction · 0.85

Tested by

no test coverage detected