Skip to content

Commit

Permalink
Merge pull request #3006 from maxime/bug/client-slack-and-postgres
Browse files Browse the repository at this point in the history
fix: client-slack & adapter-postgres: Ensure the connection between user and room before creating a memory,…
  • Loading branch information
tcm390 authored Jan 30, 2025
2 parents 4b9510d + 22b6a7c commit bdf9581
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions packages/client-slack/src/messages.ts
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,15 @@ export class MessageManager {
`${event.ts}-${this.runtime.agentId}`
);

// Ensure both the sender and agent are properly set up in the room
await this.runtime.ensureConnection(
userId,
roomId,
event.user,
event.user,
"slack"
);

// Create initial memory
console.log("💾 Step 5: Creating initial memory");
const content: Content = {
Expand Down

0 comments on commit bdf9581

Please sign in to comment.