Skip to content

Commit

Permalink
fix: perm check for thread DMs
Browse files Browse the repository at this point in the history
  • Loading branch information
nikkothari22 committed Dec 6, 2024
1 parent 3f4f16b commit ea9b543
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions raven/api/threads.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ def create_thread(message_id):
if creator != frappe.session.user:
frappe.get_doc(
{"doctype": "Raven Channel Member", "channel_id": thread_channel.name, "user_id": creator}
).insert()
).insert(ignore_permissions=True)

else:
# By now, the creator of the thread and the creator of the original message should be added as participants
Expand All @@ -113,7 +113,7 @@ def create_thread(message_id):
"channel_id": thread_channel.name,
"user_id": peer_user_id,
}
).insert()
).insert(ignore_permissions=True)

# Update the message to mark it as a thread
thread_message.is_thread = 1
Expand Down

0 comments on commit ea9b543

Please sign in to comment.