This commit is contained in:
0x1eef 2023-10-07 10:09:53 -03:00
parent 88630bae1b
commit 599f37d2fe
2 changed files with 4 additions and 3 deletions

View file

@ -1,7 +1,7 @@
module Mixin::T
def t(locale, key, locals = {})
str = [locale, *key.split(".")].inject(i18n) { |h, k| h[k] }
format(str, locals)
def t(locale, key, local_assigns = {})
str = [locale, *key.split(".")].inject(i18n) { _1[_2] }
format(str, local_assigns)
end
def i18n

@ -0,0 +1 @@
Subproject commit d75b511adc63465b3b0bce67395c25512c48a137