<?php

namespace App\Http\Controllers;

use App\Models\User;
use Illuminate\Http\Request;

class AuthController extends Controller
{
    public function user(Request $request){
        $user = User::find(auth()->id());
        $user->functions = collect($user->fnctions());
        return $user;
    }
}
