X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/06cece27fe691e321cf42a03e3ec08c464ac1444..00c0a943eada2301726db0f2ef9974691dd84ad9:/app/helpers/note_helper.rb diff --git a/app/helpers/note_helper.rb b/app/helpers/note_helper.rb index 0ba503228..7a75a4ff5 100644 --- a/app/helpers/note_helper.rb +++ b/app/helpers/note_helper.rb @@ -1,9 +1,11 @@ module NoteHelper include ActionView::Helpers::TranslationHelper - def note_description(author, description) + def note_description(author, description, first_comment) if !author.nil? && author.status == "deleted" RichText.new("text", t("notes.show.description_when_author_is_deleted")) + elsif first_comment&.event != "opened" + RichText.new("text", t("notes.show.description_when_there_is_no_opening_comment")) else description end