<?php

namespace App\Http\Controllers;

use App\Models\Pro;
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
use Illuminate\Foundation\Bus\DispatchesJobs;
use Illuminate\Foundation\Validation\ValidatesRequests;
use Illuminate\Routing\Controller as BaseController;


class Controller extends BaseController
{
    use AuthorizesRequests, DispatchesJobs, ValidatesRequests;

    public function __construct()
    {
        $session = get_current_session();
        if($session && $session->pro) {
            view()->share('pro', $session->pro);
            view()->share('performer', $session);
        }
        view()->share('pros', Pro::all());
    }
}
