<?php

namespace App\Listeners\Packages;

use App\Events\Packages\TenantPackageEventThresholdReached;
use App\Jobs\Packages\SendTenantPackageEventThresholdWarning;

class QueueTenantEventThresholdNotification
{
    public function handle(TenantPackageEventThresholdReached $event): void
    {
        SendTenantPackageEventThresholdWarning::dispatch(
            $event->tenantPackage->id,
            $event->threshold,
            $event->limit,
            $event->used
        );
    }
}
