<?php

namespace App\Http\Middleware;

use Closure;
use Illuminate\Http\Request;

class CheckClientSession
{
    public function handle(Request $request, Closure $next)
    {
        if (!session('client')) {
            return redirect()->route('login');
        }

        return $next($request);
    }
}
