From 9c51c2569a4c28db2a1f461a7cfeebb06823fa80 Mon Sep 17 00:00:00 2001 From: OSBotify Date: Tue, 12 Dec 2023 20:49:46 +0000 Subject: [PATCH 1/3] Update version to 1.4.11-22 (cherry picked from commit 292ad52549b0d6fc6f5bbb9fa73a9eb4ead72c2e) --- android/app/build.gradle | 4 ++-- ios/NewExpensify/Info.plist | 2 +- ios/NewExpensifyTests/Info.plist | 2 +- package-lock.json | 4 ++-- package.json | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/android/app/build.gradle b/android/app/build.gradle index 0e2a7b803001..b8205a21d925 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -91,8 +91,8 @@ android { minSdkVersion rootProject.ext.minSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion multiDexEnabled rootProject.ext.multiDexEnabled - versionCode 1001041121 - versionName "1.4.11-21" + versionCode 1001041122 + versionName "1.4.11-22" } flavorDimensions "default" diff --git a/ios/NewExpensify/Info.plist b/ios/NewExpensify/Info.plist index ee5608a5056c..29d2bcc0e386 100644 --- a/ios/NewExpensify/Info.plist +++ b/ios/NewExpensify/Info.plist @@ -40,7 +40,7 @@ CFBundleVersion - 1.4.11.21 + 1.4.11.22 ITSAppUsesNonExemptEncryption LSApplicationQueriesSchemes diff --git a/ios/NewExpensifyTests/Info.plist b/ios/NewExpensifyTests/Info.plist index effb2de8bfc2..7728e7e588b2 100644 --- a/ios/NewExpensifyTests/Info.plist +++ b/ios/NewExpensifyTests/Info.plist @@ -19,6 +19,6 @@ CFBundleSignature ???? CFBundleVersion - 1.4.11.21 + 1.4.11.22 diff --git a/package-lock.json b/package-lock.json index f94560fb57cf..3d7ef5e8a012 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "new.expensify", - "version": "1.4.11-21", + "version": "1.4.11-22", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "new.expensify", - "version": "1.4.11-21", + "version": "1.4.11-22", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/package.json b/package.json index 4f5f7979d6cb..a811ecd856e8 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "new.expensify", - "version": "1.4.11-21", + "version": "1.4.11-22", "author": "Expensify, Inc.", "homepage": "https://new.expensify.com", "description": "New Expensify is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.", From be71e191d9a64ff328e2d941d3fbeffdf3e889f7 Mon Sep 17 00:00:00 2001 From: Carlos Martins Date: Tue, 12 Dec 2023 13:23:30 -0700 Subject: [PATCH 2/3] Merge pull request #32943 from dukenv0307/fix/32891 Fix optimistic data for distance request (cherry picked from commit 380e6875331282b3dfcce27b5b9efafce4d11ee4) --- src/libs/actions/IOU.js | 31 +++++++++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) diff --git a/src/libs/actions/IOU.js b/src/libs/actions/IOU.js index de5a4da5c5f6..182a48516c4a 100644 --- a/src/libs/actions/IOU.js +++ b/src/libs/actions/IOU.js @@ -54,6 +54,32 @@ Onyx.connect({ }, }); +<<<<<<< HEAD +======= +let allTransactionDrafts = {}; +Onyx.connect({ + key: ONYXKEYS.COLLECTION.TRANSACTION_DRAFT, + waitForCollectionCallback: true, + callback: (val) => { + allTransactionDrafts = val || {}; + }, +}); + +let allTransactionViolations; +Onyx.connect({ + key: ONYXKEYS.COLLECTION.TRANSACTION_VIOLATIONS, + waitForCollectionCallback: true, + callback: (val) => { + if (!val) { + allTransactionViolations = {}; + return; + } + + allTransactionViolations = val; + }, +}); + +>>>>>>> 380e687 (Merge pull request #32943 from dukenv0307/fix/32891) let allDraftSplitTransactions; Onyx.connect({ key: ONYXKEYS.COLLECTION.SPLIT_TRANSACTION_DRAFT, @@ -642,11 +668,12 @@ function getMoneyRequestInformation( // data. This is a big can of worms to change it to `Onyx.merge()` as explored in https://expensify.slack.com/archives/C05DWUDHVK7/p1692139468252109. // I want to clean this up at some point, but it's possible this will live in the code for a while so I've created https://github.com/Expensify/App/issues/25417 // to remind me to do this. - const existingTransaction = existingTransactionID && TransactionUtils.getTransaction(existingTransactionID); - if (existingTransaction) { + const existingTransaction = allTransactionDrafts[`${ONYXKEYS.COLLECTION.TRANSACTION_DRAFT}${CONST.IOU.OPTIMISTIC_TRANSACTION_ID}`]; + if (existingTransaction && existingTransaction.iouRequestType === CONST.IOU.REQUEST_TYPE.DISTANCE) { optimisticTransaction = { ...optimisticTransaction, ...existingTransaction, + transactionID: optimisticTransaction.transactionID, }; } From fda6d07fa8e83eb59c6de62f15637b70738b06cf Mon Sep 17 00:00:00 2001 From: Carlos Martins Date: Tue, 12 Dec 2023 13:58:37 -0700 Subject: [PATCH 3/3] resolve conflicts --- src/libs/actions/IOU.js | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/src/libs/actions/IOU.js b/src/libs/actions/IOU.js index 182a48516c4a..5606a58cc1ea 100644 --- a/src/libs/actions/IOU.js +++ b/src/libs/actions/IOU.js @@ -54,8 +54,6 @@ Onyx.connect({ }, }); -<<<<<<< HEAD -======= let allTransactionDrafts = {}; Onyx.connect({ key: ONYXKEYS.COLLECTION.TRANSACTION_DRAFT, @@ -65,21 +63,6 @@ Onyx.connect({ }, }); -let allTransactionViolations; -Onyx.connect({ - key: ONYXKEYS.COLLECTION.TRANSACTION_VIOLATIONS, - waitForCollectionCallback: true, - callback: (val) => { - if (!val) { - allTransactionViolations = {}; - return; - } - - allTransactionViolations = val; - }, -}); - ->>>>>>> 380e687 (Merge pull request #32943 from dukenv0307/fix/32891) let allDraftSplitTransactions; Onyx.connect({ key: ONYXKEYS.COLLECTION.SPLIT_TRANSACTION_DRAFT,