Skip to content

Commit 94d374a

Browse files
authored
Merge pull request elizaOS#1154 from odilitime/fix-lint
fix: fix direct-client ability to start agents
2 parents 0a23d6d + 79cf0df commit 94d374a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

agent/src/index.ts

+5
Original file line numberDiff line numberDiff line change
@@ -647,6 +647,11 @@ const startAgents = async () => {
647647
elizaLogger.error("Error starting agents:", error);
648648
}
649649

650+
// upload some agent functionality into directClient
651+
directClient.startAgent = async character => {
652+
// wrap it so we don't have to inject directClient later
653+
return startAgent(character, directClient)
654+
};
650655
directClient.start(serverPort);
651656

652657
elizaLogger.log("Visit the following URL to chat with your agents:");

0 commit comments

Comments
 (0)