From: Anton Khorev Date: Tue, 10 Sep 2024 07:51:50 +0000 (+0300) Subject: Guess translation scope from controller name if not provided X-Git-Tag: live~210^2 X-Git-Url: https://git.openstreetmap.org./rails.git/commitdiff_plain/cb65cd9adc7240330922a7c11fd57c55521f3074 Guess translation scope from controller name if not provided --- diff --git a/app/views/diary_comments/_page.html.erb b/app/views/diary_comments/_page.html.erb index 20663a176..cc6019cff 100644 --- a/app/views/diary_comments/_page.html.erb +++ b/app/views/diary_comments/_page.html.erb @@ -19,7 +19,6 @@ <%= render "shared/pagination", - :translation_scope => "shared.pagination.diary_comments", :newer_id => @newer_comments_id, :older_id => @older_comments_id %> diff --git a/app/views/diary_entries/_page.html.erb b/app/views/diary_entries/_page.html.erb index f0a99928f..c44a5417e 100644 --- a/app/views/diary_entries/_page.html.erb +++ b/app/views/diary_entries/_page.html.erb @@ -4,7 +4,6 @@ <%= render @entries %> <%= render "shared/pagination", - :translation_scope => "shared.pagination.diary_entries", :newer_id => @newer_entries_id, :older_id => @older_entries_id %> diff --git a/app/views/issues/_page.html.erb b/app/views/issues/_page.html.erb index 8cada7564..f625f0e04 100644 --- a/app/views/issues/_page.html.erb +++ b/app/views/issues/_page.html.erb @@ -36,7 +36,6 @@ <%= render "shared/pagination", - :translation_scope => "shared.pagination.issues", :newer_id => @newer_issues_id, :older_id => @older_issues_id %> <% end %> diff --git a/app/views/shared/_pagination.html.erb b/app/views/shared/_pagination.html.erb index be701bc23..f10d0a9dc 100644 --- a/app/views/shared/_pagination.html.erb +++ b/app/views/shared/_pagination.html.erb @@ -1,3 +1,4 @@ +<% translation_scope ||= "shared.pagination.#{controller.controller_name}" %>