[openstreetmap/openstreetmap-website] Rework UI to hide/delete/suspend users (PR #6564)
Tom Hughes
notifications at github.com
Thu Dec 4 13:37:47 UTC 2025
tomhughes left a comment (openstreetmap/openstreetmap-website#6564)
> I also noticed that [`HeatmapsController#show` checks for `@user` to be set](https://github.com/openstreetmap/openstreetmap-website/blob/6ca74538293c56da5309fdde0a2b956207126de2/app/controllers/users/heatmaps_controller.rb#L16). If it's not set, then `@heatmap_data` won't be set and the view will fail anyway. From here, I think it makes sense to check for `@heatmap_data` in the view, as the controller does allow for the possibility of not setting it.
Or should the controller error if asked for a heatmap when there's no user?
Note that `@user` there is derived from the arguments to the controller - it's not the logged in user. In fact there's no need to be logged in at all to call that URL so I'm not sure your theory about the missing session works?
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6564#issuecomment-3612309734
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/pull/6564/c3612309734 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20251204/c2db9306/attachment.htm>
More information about the rails-dev
mailing list