<?php

namespace App\Providers;

use Illuminate\Support\Facades\Broadcast;
use Illuminate\Support\ServiceProvider;

class BroadcastServiceProvider extends ServiceProvider
{
    /**
     * Bootstrap any application services.
     */
    public function boot(): void
    {
        // if (app()->environment('production')) {
        //     Broadcast::routes(['middleware' => ['jwt.auth']]); # para server
        // }else{
            Broadcast::routes(['middleware' => 'jwt:auth', 'prefix' => 'api']); # para local
        // }

        require base_path('routes/channels.php');
    }
}
