This repository has been archived on 2025-01-22. You can view files and clone it, but cannot push or open issues or pull requests.
limepot-xyz/mybulma/node_modules/agent-base/dist/src/promisify.js
2023-01-27 19:21:00 -07:00

18 lines
No EOL
495 B
JavaScript

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
function promisify(fn) {
return function (req, opts) {
return new Promise((resolve, reject) => {
fn.call(this, req, opts, (err, rtn) => {
if (err) {
reject(err);
}
else {
resolve(rtn);
}
});
});
};
}
exports.default = promisify;
//# sourceMappingURL=promisify.js.map