Skip to content

Commit

Permalink
minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
FitseTLT committed Dec 24, 2024
1 parent 7999453 commit e755386
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libs/TransactionUtils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -934,7 +934,7 @@ function shouldShowViolation({
* but if we can't determine they cannot edit it, we opted to show the RBR instead of hiding it.
*/
function canEditTransaction(transactionID: string, parentReportAction: OnyxEntry<ReportAction>): boolean {
const report = ReportUtils.getReport(parentReportAction?.childReportID ?? '-1');
const report = allReports?.[`${ONYXKEYS.COLLECTION.REPORT}${parentReportAction?.childReportID ?? CONST.DEFAULT_NUMBER_ID}`];
const transaction = getTransaction(transactionID ?? '-1');
if (report && transaction && parentReportAction) {
const canUserPerformWriteAction = !!ReportUtils.canUserPerformWriteAction(report);
Expand Down

0 comments on commit e755386

Please sign in to comment.