UNPKG

openclaw

Version:

Multi-channel AI gateway with extensible messaging integrations

15 lines (14 loc) 582 B
import { s as hasOutboundReplyContent } from "./reply-payload-D-VMfpYI.js"; //#region src/auto-reply/heartbeat-reply-payload.ts /** Pick the last outbound-capable reply payload for heartbeat delivery. */ function resolveHeartbeatReplyPayload(replyResult) { if (!replyResult) return; if (!Array.isArray(replyResult)) return replyResult; for (let idx = replyResult.length - 1; idx >= 0; idx -= 1) { const payload = replyResult[idx]; if (!payload) continue; if (hasOutboundReplyContent(payload)) return payload; } } //#endregion export { resolveHeartbeatReplyPayload as t };