Level 4
The correct syntax is
Route::middleware(['web', 'auth'])->group(function () {
1 like
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
What is the correct syntax for the following route group ? The second role is not working with this code. Any help ?
Route::group(['middleware' => ['auth', 'role:broker, individual' ]], function () {
The correct syntax is
Route::middleware(['web', 'auth'])->group(function () {
Please or to participate in this conversation.