Skip to content

Commit

Permalink
Merge pull request #30115 from jeet-dhandha/fix-28262
Browse files Browse the repository at this point in the history
fix: console error old-dot to new-dot new workspace transition
  • Loading branch information
Li357 authored Oct 30, 2023
2 parents fa63485 + 7132907 commit 0df9c69
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ function CentralPaneNavigator() {
<Stack.Screen
name={SCREENS.REPORT}
// We do it this way to avoid adding the url params to url
initialParams={{openOnAdminRoom: openOnAdminRoom ? 'true' : undefined}}
initialParams={{openOnAdminRoom: openOnAdminRoom === 'true' || undefined}}
options={{
headerShown: false,
title: 'New Expensify',
Expand Down
14 changes: 7 additions & 7 deletions src/libs/ReportUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -2539,7 +2539,7 @@ function buildOptimisticIOUReportAction(
actionName: CONST.REPORT.ACTIONS.TYPE.IOU,
actorAccountID: currentUserAccountID,
automatic: false,
avatar: lodashGet(currentUserPersonalDetails, 'avatar', UserUtils.getDefaultAvatar(currentUserAccountID)),
avatar: lodashGet(currentUserPersonalDetails, 'avatar', UserUtils.getDefaultAvatarURL(currentUserAccountID)),
isAttachment: false,
originalMessage,
message: getIOUReportActionMessage(iouReportID, type, amount, comment, currency, paymentType, isSettlingUp),
Expand Down Expand Up @@ -2577,7 +2577,7 @@ function buildOptimisticApprovedReportAction(amount, currency, expenseReportID)
actionName: CONST.REPORT.ACTIONS.TYPE.APPROVED,
actorAccountID: currentUserAccountID,
automatic: false,
avatar: lodashGet(currentUserPersonalDetails, 'avatar', UserUtils.getDefaultAvatar(currentUserAccountID)),
avatar: lodashGet(currentUserPersonalDetails, 'avatar', UserUtils.getDefaultAvatarURL(currentUserAccountID)),
isAttachment: false,
originalMessage,
message: getIOUReportActionMessage(expenseReportID, CONST.REPORT.ACTIONS.TYPE.APPROVED, Math.abs(amount), '', currency),
Expand Down Expand Up @@ -2690,7 +2690,7 @@ function buildOptimisticModifiedExpenseReportAction(transactionThread, oldTransa
actionName: CONST.REPORT.ACTIONS.TYPE.MODIFIEDEXPENSE,
actorAccountID: currentUserAccountID,
automatic: false,
avatar: lodashGet(currentUserPersonalDetails, 'avatar', UserUtils.getDefaultAvatar(currentUserAccountID)),
avatar: lodashGet(currentUserPersonalDetails, 'avatar', UserUtils.getDefaultAvatarURL(currentUserAccountID)),
created: DateUtils.getDBTime(),
isAttachment: false,
message: [
Expand Down Expand Up @@ -2770,7 +2770,7 @@ function buildOptimisticTaskReportAction(taskReportID, actionName, message = '')
actionName,
actorAccountID: currentUserAccountID,
automatic: false,
avatar: lodashGet(currentUserPersonalDetails, 'avatar', UserUtils.getDefaultAvatar(currentUserAccountID)),
avatar: lodashGet(currentUserPersonalDetails, 'avatar', UserUtils.getDefaultAvatarURL(currentUserAccountID)),
isAttachment: false,
originalMessage,
message: [
Expand Down Expand Up @@ -2890,7 +2890,7 @@ function buildOptimisticCreatedReportAction(emailCreatingAction, created = DateU
},
],
automatic: false,
avatar: lodashGet(allPersonalDetails, [currentUserAccountID, 'avatar'], UserUtils.getDefaultAvatar(currentUserAccountID)),
avatar: lodashGet(allPersonalDetails, [currentUserAccountID, 'avatar'], UserUtils.getDefaultAvatarURL(currentUserAccountID)),
created,
shouldShow: true,
};
Expand Down Expand Up @@ -2929,7 +2929,7 @@ function buildOptimisticEditedTaskReportAction(emailEditingTask) {
},
],
automatic: false,
avatar: lodashGet(allPersonalDetails, [currentUserAccountID, 'avatar'], UserUtils.getDefaultAvatar(currentUserAccountID)),
avatar: lodashGet(allPersonalDetails, [currentUserAccountID, 'avatar'], UserUtils.getDefaultAvatarURL(currentUserAccountID)),
created: DateUtils.getDBTime(),
shouldShow: false,
};
Expand All @@ -2948,7 +2948,7 @@ function buildOptimisticClosedReportAction(emailClosingReport, policyName, reaso
actionName: CONST.REPORT.ACTIONS.TYPE.CLOSED,
actorAccountID: currentUserAccountID,
automatic: false,
avatar: lodashGet(allPersonalDetails, [currentUserAccountID, 'avatar'], UserUtils.getDefaultAvatar(currentUserAccountID)),
avatar: lodashGet(allPersonalDetails, [currentUserAccountID, 'avatar'], UserUtils.getDefaultAvatarURL(currentUserAccountID)),
created: DateUtils.getDBTime(),
message: [
{
Expand Down

0 comments on commit 0df9c69

Please sign in to comment.