I got this error when users click their verification email link. I use $gs as general settings for my administration panel to choose users will verify their email or not . But its ON and thus this error.
        $data[0] = 1;
        $data[1] = redirect()->intended(route('user-dashboard'))->getTargetUrl();
        return response()->json($data);
        }
}
public function token($token)
{
        **if($gs->is_verification_email == 0)**
        {       
    $user = User::where('verification_link','=',$token)->first();
    if(isset($user))
    {
        $user->email_verified = 'Yes';
        $user->update();
                if (Session::has('affilate')) 
                {
                    $referral = User::findOrFail(Session::get('affilate'));
                    $user->referral_id = $referral->id;
                    $user->update();
                }
        $notification = new Notification;
        $notification->user_id = $user->id;
        $notification->save();
        Auth::guard('web')->login($user); 
        return redirect()->route('user-dashboard')->with('success','Email Verified Successfully');
Arguments "Undefined variable: gs"
