Skip to content
Snippets Groups Projects
Commit e9f5720c authored by Teal's avatar Teal
Browse files

feat: fix telegram link sanitizer

parent 075b0956
No related branches found
No related tags found
No related merge requests found
Pipeline #39597 passed
...@@ -49,7 +49,7 @@ class TelegramGroupChatNotificationJob < NotificationJob ...@@ -49,7 +49,7 @@ class TelegramGroupChatNotificationJob < NotificationJob
# Sanitize HTML, keeping only allowed tags and attributes # Sanitize HTML, keeping only allowed tags and attributes
sanitizer = Rails::Html::SafeListSanitizer.new sanitizer = Rails::Html::SafeListSanitizer.new
text_to_send = sanitizer.sanitize(text_with_newlines, tags: allowed_tags, attributes: allowed_attributes) text_to_send = sanitizer.sanitize(text_with_newlines, tags: allowed_tags, attributes: allowed_attributes.values.flatten)
Rails.logger.info("TelegramGroupChatNotificationJob: Sending message: #{text_to_send[0..100]}...") Rails.logger.info("TelegramGroupChatNotificationJob: Sending message: #{text_to_send[0..100]}...")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment