[openstreetmap/openstreetmap-website] Fixes bug when deleted user's note lacks comments (PR #5609)

Anton Khorev notifications at github.com
Thu Feb 6 15:41:26 UTC 2025


@AntonKhorev commented on this pull request.



> @@ -52,10 +52,10 @@
     <% end %>
   </div>
 
-  <% if @note_comments.length > 1 %>
+  <% if @note_comments.length > (!@note.author.nil? && @note.author.status == "deleted" ? 0 : 1) %>

Maybe but nobody is complaining about this message. It mostly means that the note was created by an anonymous user because anonymous comments were disabled years ago. So the message probably should say just that the note was created by an anonymous user unless there are also anonymous comments.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/5609#discussion_r1944953160
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/5609/review/2599062003 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250206/540edf95/attachment-0001.htm>


More information about the rails-dev mailing list