title: Message sending through session isn't showing
body: <p>In my laravel-7 application I am sending custom message for invalid login in blade through controller. but message is not showing in blade. also tail me if I am doing anything wrong.
  in blade</p>
  <pre><code>&lt;div class=&quot;card-body&quot;&gt;
  
                   
                      @if(session()-&gt;has('message'))
                          &lt;div class=&quot;alert alert-{{session('type')}}&quot;&gt;
                              &lt;li&gt;{{session('message')}}&lt;/li&gt;
                          &lt;/div&gt;
                      @endif
  
  
  
                      &lt;form action=&quot;{{route('login')}}&quot; method=&quot;post&quot; class=&quot;form&quot;&gt;
                          @csrf
                          &lt;div class=&quot;form-group&quot;&gt;
                              &lt;label for=&quot;email&quot;&gt;Email address&lt;/label&gt;
                              &lt;input type=&quot;email&quot; name=&quot;email&quot; class=&quot;form-control&quot; id=&quot;email&quot; placeholder=&quot;Enter email&quot; value=&quot;{{old('email')}}&quot;&gt;
                          &lt;/div&gt;
                          &lt;div class=&quot;form-group&quot;&gt;
                              &lt;label for=&quot;password&quot;&gt;Password&lt;/label&gt;
                              &lt;input type=&quot;password&quot; name=&quot;password&quot; class=&quot;form-control&quot; id=&quot;password&quot; placeholder=&quot;Password&quot;&gt;
                          &lt;/div&gt;
                          &lt;div class=&quot;form-group&quot;&gt;
                              &lt;button type=&quot;submit&quot; class=&quot;btn btn-primary btn-block&quot;&gt;Login&lt;/button&gt;
                          &lt;/div&gt;
                      &lt;/form&gt;
  </code></pre>
  
  <p>in auth controller</p>
  <pre><code> public function processlogin(Request $request)
  {
      $this-&gt;validate($request,[
          'email'=&gt;'required|email',
          'password'=&gt;'required|min:6',
      ]);
  
      $credentials=$request-&gt;except(['_token']);
  
      if (Auth::attempt($credentials)){
          return redirect()-&gt;route('index');
      }
          $this-&gt;setErrorMessage('Invalid Credentials.');
          return redirect()-&gt;back();
  
  }
  </code></pre>
  <p>in controller</p>
  <pre><code>public function setErrorMessage($message):void
  {
      session()-&gt;flash($message);
      session()-&gt;flash('type','danger');
  }
  </code></pre>