From e5fcaee8f8a0c9badf0450fb209ff7cd7e4c0d2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Falc=C3=B3n?= Date: Mon, 16 Mar 2026 12:04:08 +0000 Subject: [PATCH] fix(settings): restore budgets settings redirect (#228) ## Summary - restore the legacy `/settings/budgets` route as a redirect to `/budgets` so old settings links no longer trigger a missing Inertia page - add a feature test covering the redirect to prevent the broken route from resurfacing ## Testing - php artisan test --compact tests/Feature/Settings/BudgetSettingsRedirectTest.php --- routes/settings.php | 2 ++ .../Settings/BudgetSettingsRedirectTest.php | 16 ++++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 tests/Feature/Settings/BudgetSettingsRedirectTest.php diff --git a/routes/settings.php b/routes/settings.php index 8913717d..57de6a45 100644 --- a/routes/settings.php +++ b/routes/settings.php @@ -47,6 +47,8 @@ Route::middleware('auth')->group(function () { Route::patch('settings/labels/{label}', [LabelController::class, 'update'])->name('labels.update'); Route::delete('settings/labels/{label}', [LabelController::class, 'destroy'])->name('labels.destroy'); + Route::redirect('settings/budgets', '/budgets')->name('budgets.settings'); + Route::get('settings/automation-rules', [\App\Http\Controllers\Settings\AutomationRuleController::class, 'index'])->name('automation-rules.index'); Route::post('settings/automation-rules', [\App\Http\Controllers\Settings\AutomationRuleController::class, 'store'])->name('automation-rules.store'); Route::patch('settings/automation-rules/{automationRule}', [\App\Http\Controllers\Settings\AutomationRuleController::class, 'update'])->name('automation-rules.update'); diff --git a/tests/Feature/Settings/BudgetSettingsRedirectTest.php b/tests/Feature/Settings/BudgetSettingsRedirectTest.php new file mode 100644 index 00000000..6b26a4af --- /dev/null +++ b/tests/Feature/Settings/BudgetSettingsRedirectTest.php @@ -0,0 +1,16 @@ +create(['onboarded_at' => now()]); + + actingAs($user); + + $response = get(route('budgets.settings')); + + $response->assertRedirect(route('budgets.index')); +});