Skip to content

Commit

Permalink
Reset teamId on octane
Browse files Browse the repository at this point in the history
  • Loading branch information
erikn69 authored Nov 9, 2023
1 parent 62f22e1 commit e523beb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/PermissionServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,9 @@ protected function registerOctaneListener(): void
$dispatcher = $this->app[Dispatcher::class];
// @phpstan-ignore-next-line
$dispatcher->listen(\Laravel\Octane\Events\OperationTerminated::class, OctaneReloadPermissions::class);
$dispatcher->listen(function (\Laravel\Octane\Events\OperationTerminated $event) { // @phpstan-ignore-line
$event->sandbox->make(PermissionRegistrar::class)->setPermissionsTeamId(null); // @phpstan-ignore-line
});
}

protected function registerModelBindings(): void
Expand Down

0 comments on commit e523beb

Please sign in to comment.