In my program i called a controller function using redirect action method which is commonly applied for 2 prefix routes(admin,manager) when i am on admin route i tried to call the controller function which triggers the manager route controller function here is the controller call
return redirect()->action('UserController@index');
prefix routes definied
Route::group(array('prefix' => 'admin'), function(){
Route::get('/user', 'UserController@index');
});
Route::group(array('prefix' => 'manager'), function(){
Route::get('/user', 'UserController@index');
});
when i am on admin prefix localhost/admin/user route. i triggered controller call return redirect()->action('UserController@index'); which triggers the manager prefix controller. the route will changed to localhost/manager/user why this is happening please help me on this and i am using LARAVEL 5.2
Thanks in advance