src/AuthServiceProvider.php
<?php
namespace EscolaLms\Webinar;
use EscolaLms\Webinar\Models\Webinar;
use EscolaLms\Webinar\Policies\WebinarPolicy;
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
use Laravel\Passport\Passport;
class AuthServiceProvider extends ServiceProvider
{
protected $policies = [
Webinar::class => WebinarPolicy::class,
];
public function boot()
{
$this->registerPolicies();
if (!$this->app->routesAreCached() && method_exists(Passport::class, 'routes')) {
Passport::routes();
}
}
}