diff options
Diffstat (limited to 'lib/gitlab/discussions_diff/highlight_cache.rb')
-rw-r--r-- | lib/gitlab/discussions_diff/highlight_cache.rb | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/gitlab/discussions_diff/highlight_cache.rb b/lib/gitlab/discussions_diff/highlight_cache.rb index 369c6b87fb4..1f64883cb69 100644 --- a/lib/gitlab/discussions_diff/highlight_cache.rb +++ b/lib/gitlab/discussions_diff/highlight_cache.rb @@ -43,11 +43,7 @@ module Gitlab next unless lines JSON.parse(lines).map! do |line| - line = line.with_indifferent_access - rich_text = line[:rich_text] - line[:rich_text] = rich_text&.html_safe - - Gitlab::Diff::Line.init_from_hash(line) + Gitlab::Diff::Line.safe_init_from_hash(line) end end end |