MCPcopy Create free account
hub / github.com/TruthHun/BookStack / errorAdapter

Function errorAdapter

static/word2md/mammoth.browser.js:6685–6696  ·  view source on GitHub ↗
(reason, nodeback)

Source from the content-addressed store, hash-verified

6683 }
6684}
6685function errorAdapter(reason, nodeback) {
6686 var promise = this;
6687 if (!reason) {
6688 var newReason = new Error(reason + "");
6689 newReason.cause = reason;
6690 reason = newReason;
6691 }
6692 var ret = tryCatch(nodeback).call(promise._boundValue(), reason);
6693 if (ret === errorObj) {
6694 async.throwLater(ret.e);
6695 }
6696}
6697
6698Promise.prototype.asCallback = Promise.prototype.nodeify = function (nodeback,
6699 options) {

Callers

nothing calls this directly

Calls 1

tryCatchFunction · 0.70

Tested by

no test coverage detected