diff --git a/src/hooks/useSearchBulkActions.ts b/src/hooks/useSearchBulkActions.ts index 1af2e40dfb48..2d45e1e21487 100644 --- a/src/hooks/useSearchBulkActions.ts +++ b/src/hooks/useSearchBulkActions.ts @@ -1048,6 +1048,7 @@ function useSearchBulkActions({queryJSON}: UseSearchBulkActionsParams) { for (const reportID of uniqueReportIDs) { const expenseReport = getReportFromSearchSnapshot(reportID, searchData, allReports); if (!expenseReport) { + Log.info('[BulkApprove] Skipping report: expense report not found in the search snapshot or Onyx', false, {reportID}); continue; } @@ -2312,6 +2313,8 @@ function useSearchBulkActions({queryJSON}: UseSearchBulkActionsParams) { const policy = policies?.[`${ONYXKEYS.COLLECTION.POLICY}${item.policyID}`]; if (policy) { submitMoneyRequestOnSearch(hash, [item as Report], [policy], getLoginByAccountID(item.ownerAccountID, personalDetails), getCurrencyDecimals); + } else { + Log.info('[BulkSubmit] Skipping report: policy not found in Onyx', false, {reportID: item?.reportID, policyID: item?.policyID}); } } // Submitting only changes the report, so the rows keep serving the snapshot's pre-submit report @@ -2493,6 +2496,7 @@ function useSearchBulkActions({queryJSON}: UseSearchBulkActionsParams) { for (const transactionID of selectedTransactionsKeys) { if (!selectedTransactions[transactionID].reportAction?.childReportID) { + Log.info('[BulkUnhold] Skipping transaction: report action has no childReportID', false, {transactionID}); continue; } const transactionViolations = allTransactionViolations?.[`${ONYXKEYS.COLLECTION.TRANSACTION_VIOLATIONS}${transactionID}`]; diff --git a/src/libs/actions/Search.ts b/src/libs/actions/Search.ts index 892c0f3d50e9..7c627cda9a5b 100644 --- a/src/libs/actions/Search.ts +++ b/src/libs/actions/Search.ts @@ -451,10 +451,12 @@ function handleActionButtonPress({ const connectedIntegration = getValidConnectedIntegration(exportPolicy); if (!connectedIntegration) { + Log.info('[SearchExport] Dropping export to accounting: policy has no valid connected integration', false, {reportID: item?.reportID, policyID: item?.policyID}); return; } if (!item?.reportID) { + Log.info('[SearchExport] Dropping export to accounting: item has no reportID'); return; }