respond-framework
Version:
create as fast you think
12 lines (11 loc) • 375 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
const awaitInReplaysOnly = function (f, onError) {
const promise = typeof f === 'function' ? f() : f; // can be function
if (!(promise instanceof Promise)) return;
this.promises.push(promise.catch(onError));
};
var _default = exports.default = awaitInReplaysOnly;