Call to a member function passes() on null
<p>I do have a feeling that I need to use Auth:: or something here to link to passes. Am I correct</p>

<p><strong>Issue Line</strong></p>

<pre><code>    if($validator-&gt;passes())
</code></pre>

<p>`
    <strong>getLoginCredentials</strong></p>

<pre><code>protected function getLoginCredentials(Request $request)
  {
    $validator = $this-&gt;loginValidation($request);

    if($validator-&gt;passes())
    {
    return[
    'email'    =&gt; Request::input('email'),
    'password' =&gt; Request::input('password'),
    'type'     =&gt; 1  
    ];

    }else{
        return redirect()-&gt;back()-&gt;withErrors();
    }
  }
</code></pre>

<p><strong>loginValidation</strong></p>

<pre><code>protected function loginValidation($request)
    {
        $rules = array(
          'email'      =&gt; 'required|email',
          'password'   =&gt; 'required',
    );
        $this-&gt;validate( $request , $rules);
    }
</code></pre>