Skip to content

Commit

Permalink
Fix createAzureCommunicationCallWithChatAdapterFromClients for breako…
Browse files Browse the repository at this point in the history
…ut rooms (#5683)

* Ensure createChatAdapterCallback is set in createAzureCommunicationCallWithChatAdapterFromClients so that a new ChatAdapter can be created when joining a breakout room

* Change files

* remove unnecessary CC
  • Loading branch information
mgamis-msft authored Mar 5, 2025
1 parent 1a36ba3 commit 2cd5e81
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"type": "patch",
"area": "fix",
"workstream": "Breakout rooms",
"comment": "Ensure createChatAdapterCallback is set for AzureCommunicationCallWithChatAdapter in createAzureCommunicationCallWithChatAdapterFromClients so that a new ChatAdapter can be created when joining a breakout room",
"packageName": "@azure/communication-react",
"email": "[email protected]",
"dependentChangeType": "patch"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"type": "patch",
"area": "fix",
"workstream": "Breakout rooms",
"comment": "Ensure createChatAdapterCallback is set for AzureCommunicationCallWithChatAdapter in createAzureCommunicationCallWithChatAdapterFromClients so that a new ChatAdapter can be created when joining a breakout room",
"packageName": "@azure/communication-react",
"email": "[email protected]",
"dependentChangeType": "patch"
}
Original file line number Diff line number Diff line change
Expand Up @@ -1471,7 +1471,12 @@ export const createAzureCommunicationCallWithChatAdapterFromClients = async ({
callAdapterOptions
);
const chatAdapter = await createAzureCommunicationChatAdapterFromClient(chatClient, chatThreadClient);
return new AzureCommunicationCallWithChatAdapter(callAdapter, chatAdapter);
const callWithChatAdapter = new AzureCommunicationCallWithChatAdapter(callAdapter, chatAdapter);
/* @conditional-compile-remove(breakout-rooms) */
callWithChatAdapter.setCreateChatAdapterCallback((threadId: string) =>
createAzureCommunicationChatAdapterFromClient(chatClient, chatClient.getChatThreadClient(threadId))
);
return callWithChatAdapter;
};

/**
Expand Down

0 comments on commit 2cd5e81

Please sign in to comment.