Laravel Sail with Octane (Swoole) and Breeze, and when I log out an error occurs.
Laravel sail with Octane (Swoole) and Breeze, and when I log out an error occurs.
Laravel Version
10.39.0 PHP Version
8.3.1 Database Driver & Version
PostgreSQL 15 Description
I'm using Laravel sail with Octane and Breeze, and when I log out an error occurs.
Illuminate\ Contracts\ Container\ BindingResolutionException PHP 8.3.1 10.39.0 Target [Illuminate\Contracts\Routing\ResponseFactory] is not instantiable while building [Illuminate\Routing\ViewController].
Error: https://flareapp.io/share/w5BRn2d5 Steps To Reproduce
Error Share with Flare APP: https://flareapp.io/share/w5BRn2d5
The solution I found (but I'm not sure if this has any negative impact):
LINK: livewire/livewire#6942
File: vendor/livewire/livewire/src/Mechanisms/PersistentMiddleware/PersistentMiddleware.php
protected function getApplicablePersistentMiddleware($request)
{
$route = $this->getRouteFromRequest($request);
if (! $route) return [];
// ADD THIS:
$route->setContainer(app());
$middleware = app('router')->gatherRouteMiddleware($route);
return $this->filterMiddlewareByPersistentMiddleware($middleware);
}
Please or to participate in this conversation.