<?php

namespace App\Policies;

use App\Models\Company;
use App\Models\User;

class CompanyPolicy
{
    public function update(User $user, Company $company): bool
    {
        return $user->company_id === $company->id
            && $user->hasAnyRole(['admin', 'manager']);
    }
}
