Commit 34ceace6 authored by Etienne Baqué's avatar Etienne Baqué

Fixed a variable name in Audit::Detail

parent c3896451
...@@ -33,7 +33,7 @@ module Audit ...@@ -33,7 +33,7 @@ module Audit
when :failed_login when :failed_login
"Failed to login with #{oath_label} authentication" "Failed to login with #{oath_label} authentication"
when :custom_message when :custom_message
detail_value detail_value_with_space
else else
text_for_change(target_detail_value) text_for_change(target_detail_value)
end end
...@@ -49,7 +49,11 @@ module Audit ...@@ -49,7 +49,11 @@ module Audit
end end
def target_detail_value def target_detail_value
@details[:target_type] == 'Operations::FeatureFlag' ? detail_value : detail_value.tr('_', ' ') @details[:target_type] == 'Operations::FeatureFlag' ? detail_value : detail_value_with_space
end
def detail_value_with_space
detail_value.tr('_', ' ')
end end
def detail_value def detail_value
......
...@@ -20,7 +20,7 @@ shared_examples 'audit event contains custom message' do ...@@ -20,7 +20,7 @@ shared_examples 'audit event contains custom message' do
visit audit_events_url visit audit_events_url
end end
it 'user sess this message' do it 'user sees this message' do
expect(page).to have_content('Message with spaces') expect(page).to have_content('Message with spaces')
end end
......
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