Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ def render_respond_to_format_with_error_message(msg, url_or_path, http_status, e

respond_to do |format|
# Redirect use to the path and display the error message
format.html { redirect_to url_or_path, alert: msg }
format.any(:html, :pdf) { redirect_to url_or_path, alert: msg }
# Render the JSON error message (using API V1)
format.json do
@payload = { errors: [msg] }
Expand Down
Loading