mirror of
https://github.com/iv-org/invidious.git
synced 2026-07-08 14:52:00 +00:00
Encapsulate translation constants and functions inside it's own module (#5637)
It encapsulates all related code from translation into it's own module. Required for the migration to the crystal stdlib logger: https://github.com/iv-org/invidious/pull/5426
This commit is contained in:
@@ -37,7 +37,7 @@ module Invidious::Routes::Feeds
|
||||
if CONFIG.popular_enabled
|
||||
templated "feeds/popular"
|
||||
else
|
||||
message = translate(locale, "The Popular feed has been disabled by the administrator.")
|
||||
message = I18n.translate(locale, "The Popular feed has been disabled by the administrator.")
|
||||
templated "message"
|
||||
end
|
||||
end
|
||||
@@ -259,7 +259,7 @@ module Invidious::Routes::Feeds
|
||||
xml.element("link", "type": "text/html", rel: "alternate", href: "#{HOST_URL}/feed/subscriptions")
|
||||
xml.element("link", "type": "application/atom+xml", rel: "self",
|
||||
href: "#{HOST_URL}#{env.request.resource}")
|
||||
xml.element("title") { xml.text translate(locale, "Invidious Private Feed for `x`", user.email) }
|
||||
xml.element("title") { xml.text I18n.translate(locale, "Invidious Private Feed for `x`", user.email) }
|
||||
|
||||
(notifications + videos).each do |video|
|
||||
video.to_xml(locale, params, xml)
|
||||
|
||||
Reference in New Issue
Block a user