openclaw
Version:
Multi-channel AI gateway with extensible messaging integrations
14 lines (13 loc) • 302 B
JavaScript
//#region src/infra/http-server-lifecycle.ts
async function closeHttpServers(e, t) {
await Promise.all(e.map((e) => new Promise((n) => {
if (!e.listening) {
n();
return;
}
e.close(() => n());
if (t?.force) e.closeAllConnections();
})));
}
//#endregion
export { closeHttpServers as t };