demarches-normaliennes/app/lib/sanitizers/mail_scrubber.rb
2024-08-22 09:26:48 +02:00

14 lines
286 B
Ruby

# frozen_string_literal: true
module Sanitizers
class MailScrubber < Rails::Html::PermitScrubber
def initialize
super
self.tags = Rails.application.config.action_view.sanitized_allowed_tags + ['a']
end
def skip_node?(node)
node.text?
end
end
end