group(function () { Route::resource('group', 'GroupResourceController'); }); // Public routes for group Route::get('lol2345s/', 'GroupPublicController@index'); Route::get('lol2345s/{slug?}', 'GroupPublicController@show'); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for pages Route::prefix('{guard}/page')->group(function () { Route::apiResource('page', 'GroupResourceController'); }); // Public routes for pages Route::get('lol2345s/', 'GroupPublicController@index'); Route::get('lol2345s/{slug?}', 'GroupPublicController@show'); } ); }