// Metro module 872 (f873). import { isThenable } from "./isInstanceOf"; import { rejectedSyncPromise } from "./SyncPromise"; import { DEBUG_BUILD } from "./Module823"; import { debug } from "./consoleSandbox"; function $mk67225($env) { return (a0) => { let r48; let env23870; const r3 = $env; const r9 = $env.$parent; const r12 = r3[0]; const r11 = r3[1]; const r4 = r3[2] + 1; const r5 = env23870 = { $parent: r9 }; env23870[0] = r12; env23870[1] = r11; env23870[2] = r4; const r6 = r11[r4]; let r27 = a0; if (a0) { r27 = a0; if (r6) { const r29 = r6({ ...a0 }, r12); const r14 = r9[0]; const r13 = r9[1]; if (r14(r13[2]).DEBUG_BUILD && r29 === null) { r14(r13[3]).debug.log(`Event processor "${r6.id || "?"}" dropped event`); } if (r14(r13[0]).isThenable(r29)) { r48 = r29.then($mk67225(r5)); } else { let env23871; const r45 = r4 + 1; const r46 = env23871 = { $parent: r9 }; env23871[0] = r12; env23871[1] = r11; env23871[2] = r45; const r47 = r11[r45]; r48 = r29; if (r29) { r48 = r29; if (r47) { const r53 = r47({ ...r29 }, r12); if (r14(r13[2]).DEBUG_BUILD && r53 === null) { r14(r13[3]).debug.log(`Event processor "${r47.id || "?"}" dropped event`); } r48 = r14(r13[0]).isThenable(r53) ? r53.then($mk67225(r46)) : (0, r9[2])(r53, r12, r11, r45 + 1); } } } r27 = r48; } } return r27; }; } let env712 = {}; const _notifyEventProcessors = function _notifyEventProcessors(a0, a1, a2, a3) { let env12533; const r4 = env12533 = { $parent: env712 }; env12533[0] = a1; env12533[1] = a2; env12533[2] = a3; const r11 = a2[a3]; if (a0 && r11) { const r23 = r11({ ...a0 }, a1); if (DEBUG_BUILD && r23 === null) { debug.log(`Event processor "${r11.id || "?"}" dropped event`); } return isThenable(r23) ? r23.then($mk67225(r4)) : _notifyEventProcessors(r23, a1, a2, a3 + 1); } return a0; }; Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" }); export function notifyEventProcessors(a0, a1, a2, r9 = 0) { let r27; try { const r7 = _notifyEventProcessors(a1, a2, a0, r9); r27 = isThenable(r7) ? r7 : require(dependencyMap[1]).resolvedSyncPromise(r7); } catch ($e) { return rejectedSyncPromise($e); } return r27; }