MCPcopy Create free account
hub / github.com/Code-Bullet/Jump-King / initializePromise

Function initializePromise

libraries/p5.js:466–476  ·  view source on GitHub ↗
(promise, resolver)

Source from the content-addressed store, hash-verified

464}
465
466function initializePromise(promise, resolver) {
467 try {
468 resolver(function resolvePromise(value) {
469 _resolve(promise, value);
470 }, function rejectPromise(reason) {
471 _reject(promise, reason);
472 });
473 } catch (e) {
474 _reject(promise, e);
475 }
476}
477
478var id = 0;
479function nextId() {

Callers 1

PromiseFunction · 0.85

Calls 2

_resolveFunction · 0.85
_rejectFunction · 0.85

Tested by

no test coverage detected