36 lines
966 B
JavaScript
36 lines
966 B
JavaScript
// Module ID: 5441
|
|
// Function ID: 46506
|
|
// Name: asyncGeneratorStep
|
|
// Dependencies: []
|
|
|
|
// Module 5441 (asyncGeneratorStep)
|
|
function asyncGeneratorStep(arg0, arg1, arg2, arg3, arg4, arg5, arg6) {
|
|
const iter = arg0[arg5](arg6);
|
|
const value = iter.value;
|
|
if (iter.done) {
|
|
arg1(value);
|
|
} else {
|
|
const resolved = Promise.resolve(value);
|
|
resolved.then(arg3, arg4);
|
|
}
|
|
}
|
|
|
|
export default function _asyncToGenerator(arg0) {
|
|
let closure_0 = arg0;
|
|
return function() {
|
|
const self = this;
|
|
let closure_1 = arguments;
|
|
return new Promise((arg0, arg1) => {
|
|
let closure_0 = arg0;
|
|
let closure_1 = arg1;
|
|
function _next(arg0) {
|
|
callback(closure_2, callback, closure_1, _next, _throw, "next", arg0);
|
|
}
|
|
function _throw(arg0) {
|
|
callback(closure_2, callback, closure_1, _next, _throw, "throw", arg0);
|
|
}
|
|
let closure_2 = self.apply(closure_0, closure_1);
|
|
_next(undefined);
|
|
});
|
|
};
|
|
};
|