Should fix route registration using controller base prefix.

This commit is contained in:
Italo Baeza Cabrera
2022-10-28 16:26:53 -03:00
parent 0b39038873
commit 7f4465a4ef

View File

@@ -32,19 +32,19 @@ class WebAuthn
public static function routes(): void public static function routes(): void
{ {
Route::middleware('web')->group(static function (): void { Route::middleware('web')->group(static function (): void {
Route::post('webauthn/register/options') Route::post(
->uses([\App\Http\Controllers\WebAuthn\WebAuthnRegisterController::class, 'options']) 'webauthn/register/options', [\App\Http\Controllers\WebAuthn\WebAuthnRegisterController::class, 'options'
->name('webauthn.register.options'); ])->name('webauthn.register.options');
Route::post('webauthn/register') Route::post(
->uses([\App\Http\Controllers\WebAuthn\WebAuthnRegisterController::class, 'register']) 'webauthn/register', [\App\Http\Controllers\WebAuthn\WebAuthnRegisterController::class, 'register'
->name('webauthn.register'); ])->name('webauthn.register');
Route::post('webauthn/login/options') Route::post(
->uses([\App\Http\Controllers\WebAuthn\WebAuthnLoginController::class, 'options']) 'webauthn/login/options', [\App\Http\Controllers\WebAuthn\WebAuthnLoginController::class, 'options'
->name('webauthn.login.options'); ])->name('webauthn.login.options');
Route::post('webauthn/login') Route::post(
->uses([\App\Http\Controllers\WebAuthn\WebAuthnLoginController::class, 'login']) 'webauthn/login', [\App\Http\Controllers\WebAuthn\WebAuthnLoginController::class, 'login'
->name('webauthn.login'); ])->name('webauthn.login');
}); });
} }
} }