title: Laravel Authentication doesn't work properly
body: <p>I  created login form and implemented authentication for admin side of website. </p>
  
  <p>Login form works perfectly  fine ,however i can reach to admin/index without logging . I tried  middleware but even if i log in it won't let me to reach admin/index. What did i miss ? </p>
  
  <p>Here is my route , </p>
  
  <pre><code>Route::group(['prefix' =&gt; 'admin'], function () {
     Route::group(['middleware' =&gt; 'auth'], function () {
     Route::get('index', array('as' =&gt; 'admin', 'uses' =&gt; 'AdminController@admin'));
     Route::get('doctors', array('as' =&gt; 'doctors.index', 'uses' =&gt; 'DoctorsController@index'));
     Route::post('doctorstore', array('as' =&gt; 'doctors.store', 'uses' =&gt; 'DoctorsController@store'));
     Route::post('doctorsmail', array('as' =&gt; 'doctors.mail', 'uses' =&gt; 'DoctorsController@update'));
  });
  
  Route::get('/', array('as' =&gt; 'getlogin', 'uses' =&gt;'AdminController@getLogin'));
  Route::post('/', array('as' =&gt; 'postlogin', 'uses' =&gt;'AdminController@postLogin'));
  </code></pre>
  
  <p>and this is my controller </p>
  
  <pre><code>public function getLogin()
       return view('admin.login');
  
  public function postLogin(Request $request){
  
      if (Auth::attempt(['email' =&gt; Request::input('email'), 'password' =&gt; Request::input('password')])){
          return redirect()-&gt;route('admin');
      }else{
          return 'not entered ';
      }
  }
  
  public function getRegister()
  {
      return view('admin.register');
  }
  
  protected function postRegister(Request $request)
  {
      return User::create([
          'email' =&gt; $request['email'],
          'password' =&gt; bcrypt($request['password']),
      ]);
  }
  </code></pre>