Skip to content

Commit

Permalink
Merge pull request #16918 from Expensify/marcaaron-fixReport403Missin…
Browse files Browse the repository at this point in the history
…gAccess

[CP Staging] Fix infinity loading display for inaccessible report
  • Loading branch information
deetergp authored Apr 4, 2023
2 parents a4f7514 + 44632c0 commit ae7e6e1
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/libs/actions/Report.js
Original file line number Diff line number Diff line change
Expand Up @@ -366,10 +366,18 @@ function openReport(reportID, participantList = [], newReportObject = {}) {
isOptimisticReport: false,
},
};
const reportFailureData = {
onyxMethod: CONST.ONYX.METHOD.MERGE,
key: `${ONYXKEYS.COLLECTION.REPORT}${reportID}`,
value: {
isLoadingReportActions: false,
},
};

const onyxData = {
optimisticData: [optimisticReportData],
successData: [reportSuccessData],
failureData: [reportFailureData],
};

const params = {
Expand Down

0 comments on commit ae7e6e1

Please sign in to comment.