aboutsummaryrefslogtreecommitdiff
path: root/routes/web.php
diff options
context:
space:
mode:
authorFrankie B <git@diskfloppy.me>2024-06-18 02:52:19 +0100
committerFrankie B <git@diskfloppy.me>2024-06-18 02:52:19 +0100
commit02c68f854589e63ba4ee1d5a8732ba9be25ceb6a (patch)
tree3438d770d01027e115868d474be1225165ecd09e /routes/web.php
parente89a7bb329abf3cd252fea7f624acbc454d7caf4 (diff)
Move admin routes to prefix group
Diffstat (limited to 'routes/web.php')
-rw-r--r--routes/web.php16
1 files changed, 7 insertions, 9 deletions
diff --git a/routes/web.php b/routes/web.php
index 6456439..fb12e96 100644
--- a/routes/web.php
+++ b/routes/web.php
@@ -37,13 +37,11 @@ Route::post('/guestbook', [GuestbookController::class, 'addEntry'])
->middleware('rate_limit');
// Admin pages
-Route::get('/admin/guestbook', [AdminGuestbookController::class, 'show'])
- ->middleware('auth');
-Route::get('/admin/bookmarks', [AdminBookmarksController::class, 'show'])
- ->middleware('auth');
-Route::get('/admin/import', [AdminImportController::class, 'show'])
- ->middleware('auth');
-Route::post('/admin/import', [AdminImportController::class, 'submit'])
- ->name('admin.import.submit')
- ->middleware('auth');
+Route::prefix('admin')->group(function () {
+ Route::get('/admin/guestbook', [AdminGuestbookController::class, 'show']);
+ Route::get('/admin/bookmarks', [AdminBookmarksController::class, 'show']);
+ Route::get('/admin/import', [AdminImportController::class, 'show']);
+ Route::post('/admin/import', [AdminImportController::class, 'submit'])
+ ->name('admin.import.submit');
+})->middleware('auth');