corrige mise en forme commentaire

This commit is contained in:
Christophe Robillard 2020-08-10 16:02:11 +02:00
parent 971ca18082
commit eea5fd66ad
2 changed files with 6 additions and 1 deletions

View file

@ -22,4 +22,9 @@ module CommentaireHelper
template = is_current_year ? :message_date : :message_date_with_year
I18n.l(commentaire.created_at, format: template)
end
def pretty_commentaire(commentaire)
body_formatted = commentaire.sent_by_system? ? commentaire.body : simple_format(commentaire.body)
sanitize(body_formatted)
end
end