openclaw
Version:
Multi-channel AI gateway with extensible messaging integrations
1 lines • 705 B
JavaScript
import{rt as e}from"./openclaw-state-lease-heartbeat.worker-subsystem-DoPLR_ni.mjs";const t=Promise;function createDeferredCore(){return t.withResolvers()}function throwSettledAggregate(e,t){let n=e.flatMap(e=>e.status===`rejected`?[e.reason]:[]);if(n.length)throw AggregateError(n,t)}function materializeErrorStack(t){try{for(let n of e(t))try{if(!(n instanceof Error))continue;try{n.stack=String(n.stack)}catch{n.stack=`Stack trace unavailable: custom formatter failed`}}catch{}}catch{}}function collectSynchronousErrors(e,t){let n=[];for(let r of e)try{t(r)}catch(e){n.push(e)}return n}export{createDeferredCore as i,materializeErrorStack as n,throwSettledAggregate as r,collectSynchronousErrors as t};