Commit 30739d4d authored by Abdul Wadood's avatar Abdul Wadood

Replace OpenStruct with Struct in ansi2html.rb

parent c765eb69
......@@ -30,6 +30,8 @@ module Gitlab
Converter.new.convert(ansi, state)
end
Result = Struct.new(:html, :state, :append, :truncated, :offset, :size, :total, keyword_init: true) # rubocop:disable Lint/StructNewOverride
class Converter
def on_0(_)
reset
......@@ -278,9 +280,7 @@ module Gitlab
close_open_tags
# TODO: replace OpenStruct with a better type
# https://gitlab.com/gitlab-org/gitlab/issues/34305
OpenStruct.new(
Ansi2html::Result.new(
html: @out.force_encoding(Encoding.default_external),
state: state,
append: append,
......
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