Level 3
Ah just learned about the request() global function. That'll work.
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Brand new to Laravel and Spark. I am trying to filter out users based on the current users' role on a team and TeamRepository@find doesn't have access to the Request object. So I think I need to extend TeamController to override the show method. The docs say to use the Spark::swap method, but that seems to only work on methods called with Spark::interact. How would I go about extending the TeamController without making it hard to update Spark in the future? Or is there another way to accomplish that?
Please or to participate in this conversation.