Implement academy analytics, billing, and web stories updates
This commit is contained in:
@@ -114,6 +114,18 @@ Route::middleware('ensure.onboarding.complete')
|
||||
->get('/gallery/{id}/{username?}', [GalleryController::class, 'show'])
|
||||
->name('legacy.gallery'); // We need to fix to a new gallery
|
||||
|
||||
// Legacy `profile.php?uname=...` compatibility: map old profile bookmarks to
|
||||
// the canonical @username profile URL.
|
||||
Route::get('/profile.php', function () {
|
||||
$uname = trim((string) request()->query('uname', ''));
|
||||
|
||||
if ($uname === '') {
|
||||
return redirect()->to('/', 301);
|
||||
}
|
||||
|
||||
return redirect()->to('/@' . rawurlencode(strtolower($uname)), 301);
|
||||
})->name('legacy.profile.php');
|
||||
|
||||
// ── PROFILE (legacy URL patterns) ────────────────────────────────────────────
|
||||
Route::get('/user/{username}', [ProfileController::class, 'legacyByUsername'])->where('username', '[A-Za-z0-9_-]{3,20}')->name('legacy.user.profile');
|
||||
Route::get('/profile/{id}/{username?}', [ProfileController::class, 'legacyById'])->where('id', '\d+')->name('legacy.profile.id');
|
||||
|
||||
Reference in New Issue
Block a user