Commit 0f3fb24
Add shouldRestrictUserBillableActions guard to duplicate expense handlers
The duplicate expense flow never checks whether the target workspace has
expired billing. This allows users to bypass the billing restriction by
duplicating expenses into expired workspaces. Add the same
shouldRestrictUserBillableActions guard that exists in the Add Expense
handler to all duplicate expense entry points:
- useExpenseActions: DUPLICATE_EXPENSE and DUPLICATE_REPORT handlers
- MoneyRequestHeaderSecondaryActions: transaction-level DUPLICATE handler
- useSearchBulkActions: bulk DUPLICATE handler (both contexts)
Co-authored-by: Eugene Voloshchak <eVoloshchak@users.noreply.github.com>1 parent 45d6ada commit 0f3fb24
3 files changed
Lines changed: 49 additions & 3 deletions
File tree
- src
- components
- hooks
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
| 53 | + | |
53 | 54 | | |
54 | 55 | | |
55 | 56 | | |
| |||
138 | 139 | | |
139 | 140 | | |
140 | 141 | | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
141 | 145 | | |
142 | 146 | | |
143 | 147 | | |
| |||
350 | 354 | | |
351 | 355 | | |
352 | 356 | | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
353 | 365 | | |
354 | 366 | | |
355 | 367 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
317 | 317 | | |
318 | 318 | | |
319 | 319 | | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
320 | 328 | | |
321 | 329 | | |
322 | 330 | | |
| |||
369 | 377 | | |
370 | 378 | | |
371 | 379 | | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
372 | 391 | | |
373 | 392 | | |
374 | 393 | | |
375 | | - | |
376 | | - | |
377 | 394 | | |
378 | 395 | | |
379 | 396 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1056 | 1056 | | |
1057 | 1057 | | |
1058 | 1058 | | |
1059 | | - | |
| 1059 | + | |
| 1060 | + | |
| 1061 | + | |
| 1062 | + | |
| 1063 | + | |
| 1064 | + | |
| 1065 | + | |
| 1066 | + | |
| 1067 | + | |
| 1068 | + | |
1060 | 1069 | | |
1061 | 1070 | | |
1062 | 1071 | | |
| |||
1368 | 1377 | | |
1369 | 1378 | | |
1370 | 1379 | | |
| 1380 | + | |
| 1381 | + | |
| 1382 | + | |
| 1383 | + | |
| 1384 | + | |
| 1385 | + | |
| 1386 | + | |
1371 | 1387 | | |
1372 | 1388 | | |
1373 | 1389 | | |
| |||
1477 | 1493 | | |
1478 | 1494 | | |
1479 | 1495 | | |
| 1496 | + | |
1480 | 1497 | | |
1481 | 1498 | | |
1482 | 1499 | | |
| |||
0 commit comments