Commit 57c4bc2
committed
fix: accept optional CurrentUser in hasPermissionForCategory
Avoids instantiating a new CurrentUser and hitting the DB on every
call when the caller already has one. The parameter is optional to
maintain backward compatibility.1 parent d3c54bc commit 57c4bc2
1 file changed
Lines changed: 11 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
489 | 489 | | |
490 | 490 | | |
491 | 491 | | |
| 492 | + | |
492 | 493 | | |
493 | 494 | | |
494 | | - | |
495 | | - | |
496 | | - | |
497 | | - | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
498 | 505 | | |
499 | 506 | | |
500 | 507 | | |
| |||
0 commit comments