Skip to content

Commit

Permalink
add referrer to widget logs
Browse files Browse the repository at this point in the history
  • Loading branch information
mikesndrs committed Oct 22, 2024
1 parent 5d14f23 commit bc70705
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/controllers/events_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ def update_collections
def redirect
@event.widget_logs.create(widget_name: params[:widget],
action: "#{controller_name}##{action_name}",
data: @event.url, params:)
data: @event.url, params: params.merge({ referrer: request.referrer }))

redirect_to @event.url, allow_other_host: true
end
Expand All @@ -236,7 +236,7 @@ def event_params
{ host_institutions: [] }, :capacity, :contact, :recognition, :learning_objectives,
:prerequisites, :tech_requirements, :cost_basis, :cost_value, :cost_currency, :language,
external_resources_attributes: %i[id url title _destroy],
external_resources: [:url, :title], material_ids: [],
external_resources: %i[url title], material_ids: [],
llm_interaction_attributes: %i[id scrape_or_process model prompt input output needs_processing _destroy],
locked_fields: [])
end
Expand Down

0 comments on commit bc70705

Please sign in to comment.