Commit 276e78e0 authored by Martin Wortschack's avatar Martin Wortschack 🐻

handle redirect properly

parent 3b8994d1
Pipeline #29569530 failed with stages
in 41 minutes and 58 seconds
......@@ -9,8 +9,10 @@ class Admin::ApplicationSettingsController < Admin::ApplicationController
.new(@application_setting, current_user, application_setting_params)
redirect_path = params[:redirect_path] ? params[:redirect_path].to_h : admin_application_settings_path
if successful
redirect_to request.referer,
redirect_to redirect_path,
notice: 'Application settings saved successfully'
render :show
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment