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
9 changes: 8 additions & 1 deletion src/libs/actions/Task.ts
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,14 @@ function setAssigneeValue(
skipShareDestination = false,
): OnyxEntry<OnyxTypes.Report> | undefined {
let report: OnyxEntry<OnyxTypes.Report> | undefined = chatReport;
if (!isCurrentUser) {
if (isCurrentUser) {
const selfDMReportID = ReportUtils.findSelfDMReportID();
// If there is no share destination set, automatically set it to the assignee chat report
// This allows for a much quicker process when creating a new task and is likely the desired share destination most times
if (!shareToReportID && !skipShareDestination) {
setShareDestinationValue(selfDMReportID ?? '-1');
}
} else {
// Check for the chatReport by participants IDs
if (!report) {
report = ReportUtils.getChatByParticipants([assigneeAccountID, currentUserAccountID]);
Expand Down