From e333956a7203edd1a448533cd014e63efb08725e Mon Sep 17 00:00:00 2001 From: Maria D'Costa Date: Tue, 28 Mar 2023 15:46:09 +0000 Subject: [PATCH 1/2] Clear the iouReportID param in the report Onyx key after paying the IOU --- src/libs/actions/IOU.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/libs/actions/IOU.js b/src/libs/actions/IOU.js index 8a3f7ced02f7..86bb87c72437 100644 --- a/src/libs/actions/IOU.js +++ b/src/libs/actions/IOU.js @@ -849,6 +849,13 @@ function getPayMoneyRequestParams(chatReport, iouReport, recipient, paymentMetho }, }, }, + { + onyxMethod: CONST.ONYX.METHOD.MERGE, + key: `${ONYXKEYS.COLLECTION.REPORT}${chatReport.reportID}`, + value: { + iouReportID: null, + }, + }, ]; const failureData = [ From 04b9d5c7c87bbd459d1ba48b2f0ccbdea2ed7deb Mon Sep 17 00:00:00 2001 From: Maria D'Costa Date: Wed, 29 Mar 2023 15:57:56 +0000 Subject: [PATCH 2/2] Fix trailing space --- src/libs/actions/IOU.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/actions/IOU.js b/src/libs/actions/IOU.js index 86bb87c72437..b2e030f4aa02 100644 --- a/src/libs/actions/IOU.js +++ b/src/libs/actions/IOU.js @@ -855,7 +855,7 @@ function getPayMoneyRequestParams(chatReport, iouReport, recipient, paymentMetho value: { iouReportID: null, }, - }, + }, ]; const failureData = [