Move admin routes to prefix group

This commit is contained in:
floppydiskette 2024-06-18 02:52:19 +01:00
parent e89a7bb329
commit 02c68f8545
Signed by: fwoppydwisk
SSH key fingerprint: SHA256:Hqn452XQ1ETzUt/FthJu6+OFkS4NBxCv5VQSEvuk7CE

View file

@ -37,13 +37,11 @@
->middleware('rate_limit'); ->middleware('rate_limit');
// Admin pages // Admin pages
Route::get('/admin/guestbook', [AdminGuestbookController::class, 'show']) Route::prefix('admin')->group(function () {
->middleware('auth'); Route::get('/admin/guestbook', [AdminGuestbookController::class, 'show']);
Route::get('/admin/bookmarks', [AdminBookmarksController::class, 'show']) Route::get('/admin/bookmarks', [AdminBookmarksController::class, 'show']);
->middleware('auth'); Route::get('/admin/import', [AdminImportController::class, 'show']);
Route::get('/admin/import', [AdminImportController::class, 'show']) Route::post('/admin/import', [AdminImportController::class, 'submit'])
->middleware('auth'); ->name('admin.import.submit');
Route::post('/admin/import', [AdminImportController::class, 'submit'])
->name('admin.import.submit')
->middleware('auth');
})->middleware('auth');