Support the ongoing development of Laravel.io →
posted 6 years ago
Laravel.io
Last updated 2 years ago.
0
moderator Solution

Hey Piotrek,

This is done by route bindings. You can find the file here: routes/bindings.php.

So basically we tell Laravel to return an instance of a user when it tries to pass the email_address to the controller. If it doesn't finds an instance it'll throw a 404.

Last updated 6 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Peter mtr Joined 20 Oct 2017

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.