diff --git a/lib/github/markup/markdown.rb b/lib/github/markup/markdown.rb index 11cf662d..7952bd3b 100644 --- a/lib/github/markup/markdown.rb +++ b/lib/github/markup/markdown.rb @@ -6,7 +6,8 @@ class Markdown < Implementation MARKDOWN_GEMS = { "commonmarker" => proc { |content, options: {}| commonmarker_opts = [:GITHUB_PRE_LANG].concat(options.fetch(:commonmarker_opts, [])) - CommonMarker.render_html(content, commonmarker_opts, [:tagfilter, :autolink, :table, :strikethrough]) + commonmarker_exts = options.fetch(:commonmarker_exts, [:tagfilter, :autolink, :table, :strikethrough]) + CommonMarker.render_html(content, commonmarker_opts, commonmarker_exts) }, "github/markdown" => proc { |content, options: {}| GitHub::Markdown.render(content) diff --git a/test/markup_test.rb b/test/markup_test.rb index 1ff2272a..da859944 100644 --- a/test/markup_test.rb +++ b/test/markup_test.rb @@ -120,5 +120,8 @@ def test_commonmarker_options assert_equal "
hello world
\n", GitHub::Markup.render_s(GitHub::Markups::MARKUP_MARKDOWN, "hellohello