refactor: extract dashboard and message-runtime from index.ts
- Extract dashboard code into src/dashboard.ts - Extract message runtime into src/message-runtime.ts - Improve group-queue with better concurrency handling - Update agent-runner with enhanced env/config passing - Simplify DB operations and cleanup unused code - Update README for Codex SDK architecture
This commit is contained in:
@@ -34,16 +34,6 @@ export function formatOutbound(rawText: string): string {
|
||||
return text;
|
||||
}
|
||||
|
||||
export function routeOutbound(
|
||||
channels: Channel[],
|
||||
jid: string,
|
||||
text: string,
|
||||
): Promise<void> {
|
||||
const channel = channels.find((c) => c.ownsJid(jid) && c.isConnected());
|
||||
if (!channel) throw new Error(`No channel for JID: ${jid}`);
|
||||
return channel.sendMessage(jid, text);
|
||||
}
|
||||
|
||||
export function findChannel(
|
||||
channels: Channel[],
|
||||
jid: string,
|
||||
|
||||
Reference in New Issue
Block a user