Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Fix possible unprotected redirect

Christophe Bliard866bf1356ace
diff --git a/modules/budgets/app/controllers/budgets_controller.rb b/modules/budgets/app/controllers/budgets_controller.rb
index 37be70db402..02d674f3212 100644
--- a/modules/budgets/app/controllers/budgets_controller.rb
+++ b/modules/budgets/app/controllers/budgets_controller.rb
@@ -125,7 +125,7 @@ class BudgetsController < ApplicationController
if call.success?
flash[:notice] = t(:notice_successful_update)
- redirect_to(params[:back_to] || { action: 'show', id: @budget })
+ redirect_to(@budget)
else
@budget = call.result
@errors = call.errors