Skip to content

Commit

Permalink
Add logging of variant for navigation test
Browse files Browse the repository at this point in the history
This will enable us to determine which variant a log entry refers to.  This
will help with allowing us to measure performance and track errors.
  • Loading branch information
sihugh committed Aug 14, 2018
1 parent 44f6c50 commit d642ad0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions config/initializers/logstasher.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
if Object.const_defined?('LogStasher') && LogStasher.enabled
LogStasher.add_custom_fields do |fields|
fields[:govuk_content_pages_variant] = request.headers['GOVUK-ABTest-ContentPagesNav']
end
end

0 comments on commit d642ad0

Please sign in to comment.