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:
Fijxu authored and GitHub committed 2026-04-25 16:55:55 -04:00
1 parent 54365c0e2a
commit bc64cd9b67
54 files changed
+562 -558

No files matched your search

+1 -1
View File
@@ -268,7 +268,7 @@ module Invidious::Comments
end
json.field "published", published.to_unix
json.field "publishedText", translate(locale, "`x` ago", recode_date(published, locale))
json.field "publishedText", I18n.translate(locale, "`x` ago", recode_date(published, locale))
end
if node_replies && !response["commentRepliesContinuation"]?