webpage #37
-
i have added it in routes and a get local.ERROR: Invalid route action: [App\Http\Controllers\Spatie\Health\Http\Controllers\HealthCheckResultsController] |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
I too experienced the same problem but found a simple workaround for now until the real reason is discovered. Route::get('health', [HealthCheckResultsController::class, '__invoke']); |
Beta Was this translation helpful? Give feedback.
-
The problem was the base namespace of the routes: // App\Providers\RouteServiceProvider
Route::middleware('web')
->namespace($this->namespace)
->group(base_path('routes/web.php')); That adds the base namespace before HealthCheckResultsController FQN So you can remove Route::get('health', '\\'.HealthCheckResultsController::class); |
Beta Was this translation helpful? Give feedback.
-
thanks man, you saved my day. |
Beta Was this translation helpful? Give feedback.
I too experienced the same problem but found a simple workaround for now until the real reason is discovered.