<?php

namespace App\Providers;

use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
use App\Events\UserUpdated;
use App\Events\AderenteCreated;
use App\Events\PosicaoAtualizada;
use App\Listeners\BroadcastAderenteCreated;
use App\Listeners\UserSyncedListener;
use App\Listeners\SyncUserToFirestore;
use App\Listeners\VerificaProximidade;

class EventServiceProvider extends ServiceProvider
{
    protected $listen = [
        AderenteCreated::class => [
    BroadcastAderenteCreated::class,
    SyncAderenteToFirestore::class,
],
        UserUpdated::class => [
            SyncUserToFirestore::class,
        ],
        PosicaoAtualizada::class => [
            VerificaProximidade::class,
        ],
        NovaBoleyaDisponivel::class => [
            SyncNovaBoleyaToFirestore::class, // ✅ Certifique-se que está aqui
        ],
    ];
}
