code: public function boot()
      {
          $this->registerPolicies();
  
          Gate::define('hasPermission', function (User $user, string $permissionName) {
              if($user->isAdmin()) {
                  return true;
              }
  
              return $user->hasPermissionTo($permissionName);
          });
  
          Passport::routes();
  
          Passport::tokensExpireIn(Carbon::now()->addDays(15));
  
          Passport::refreshTokensExpireIn(Carbon::now()->addDays(30));
      }
docs: Register any authentication / authorization services.
  
  @return void