[openstreetmap/openstreetmap-website] Allow localized & country-specific banners (PR #6851)

Marwin Hochfelsner notifications at github.com
Tue Mar 3 05:44:31 UTC 2026


@hlfan commented on this pull request.



> @@ -15,7 +15,7 @@ def active_banners
         enddate = nil
       end
 
-      startdate&.future? || enddate&.past?
+      startdate&.future? || enddate&.past? || v[:locales]&.exclude?(I18n.locale.to_s)

This should reuse OSMs ip lookup:

https://github.com/openstreetmap/openstreetmap-website/blob/2c3fd80848d9b120b7abfb4a4d31e7491f0702e0/app/controllers/accounts/terms_controller.rb#L16

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

Message ID: <openstreetmap/openstreetmap-website/pull/6851/review/3880358420 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20260302/7ff1a973/attachment.htm>


More information about the rails-dev mailing list