Skip to content

Commit

Permalink
feat: override getThreadId()
Browse files Browse the repository at this point in the history
  • Loading branch information
marrouchi committed Nov 11, 2024
1 parent 649dc3e commit f244faf
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions api/src/extensions/channels/chatui/wrapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,16 @@ export default class ChaUiWebEventWrapper<
constructor(handler: T, event: Web.Event, channelData: any) {
super(handler, event, channelData);
}

/**
* Retrieves the thread id to which the message belongs to
*
* @returns Thread id
*/
getThreadId(): string {
if ('thread' in this._adapter.raw) {
return this._adapter.raw.thread;
}
return undefined;
}
}

0 comments on commit f244faf

Please sign in to comment.