Skip to content

Commit 34876cc

Browse files
authored
key off user id, not bot id (#1158)
1 parent f286488 commit 34876cc

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

examples/slackbot/api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ async def handle_message(payload: SlackPayload, db: Database):
8989
conversation = await db.get_thread_messages(thread_ts)
9090

9191
user_context = build_user_context(
92-
user_id=payload.authorizations[0].user_id,
92+
user_id=event.user, # Use the actual user who sent the message, not the bot
9393
user_question=cleaned_message,
9494
)
9595

0 commit comments

Comments
 (0)