Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 19 additions & 10 deletions src/libs/ReportUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6043,18 +6043,27 @@ function getTaskAssigneeChatOnyxData(
},
);

successData.push({
onyxMethod: Onyx.METHOD.MERGE,
key: `${ONYXKEYS.COLLECTION.REPORT}${assigneeChatReportID}`,
value: {
pendingFields: {
createChat: null,
// BE will send different report's participants and assigneeAccountID. We clear the optimistic ones to avoid duplicated entries
successData.push(
{
onyxMethod: Onyx.METHOD.MERGE,
key: `${ONYXKEYS.COLLECTION.REPORT}${assigneeChatReportID}`,
value: {
pendingFields: {
createChat: null,
},
isOptimisticReport: false,
participants: {[assigneeAccountID]: null},
},
isOptimisticReport: false,
// BE will send a different participant. We clear the optimistic one to avoid duplicated entries
participants: {[assigneeAccountID]: null},
},
});
{
onyxMethod: Onyx.METHOD.MERGE,
key: ONYXKEYS.PERSONAL_DETAILS_LIST,
value: {
[assigneeAccountID]: null,
},
},
);

failureData.push(
{
Expand Down