[5.2] make:auth not adding middleware => web as shown in laracasts

Posted 3 years ago by s_chahal

I have been following the Laravel 5 from Scratch series and am having a few issues with the Authentication lesson.

  1. The "php artisan make:auth" command makes all the views and everything works find as shown in the lesson. I am able to register a new user, login and logout. No problem there.

  2. However when I try to reset my password I get an error. As mentioned in the less I set the mail settings to 'log' and I still get the error. Also my error is not a 'Swift' error but a 'Maximum Nesting Level of 100 reached' error as shown here

  3. I noticed that the routes.php file created during the fresh installation of the application as shown here does not include the 'middleware' => 'web' part as shown in the laracasts lesson

  4. I changed my routes.php file to be exactly the same as the one in the laracasts lesson - yet, it DID NOT solve the error. NOTE: All other functionality of logging in, registering a new user, logging out are all working fine. Only the password reset part is giving the 'Max Nesting level of 100' error

  5. Just to be sure I also checked the What's new in 5.2 Auth and Resets in Minutes lesson to see if the Laravel 5 from Scratch lesson was old or outdated. Even in the What's New video at about the 3 min 25 sec mark the routes.php file includes the 'middleware' => 'web' part out of the box.

I am running Laravel 5.2.32 on Win10

Could someone please let me know (1) Why is the 'middleware' => 'web' part not being included in the routes.php file out of the box. (2) Is this something related to the version of Laravel.

Please sign in or create an account to participate in this conversation.