summaryrefslogtreecommitdiff
path: root/lib/banzai/filter/output_safety.rb
blob: d4ebce5d9c9fa95b5137a30191650c421de6d943 (plain)
1
2
3
4
5
6
7
8
9
10
11
# frozen_string_literal: true

module Banzai
  module Filter
    module OutputSafety
      def escape_once(html)
        html.html_safe? ? html : ERB::Util.html_escape_once(html)
      end
    end
  end
end