mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-16 00:41:42 +00:00
Merge branch 'issue-6841' into 'rails'
no fallar si los layouts no tienen traducción #6841 See merge request sutty/sutty!99
This commit is contained in:
commit
6c8bb30610
1 changed files with 3 additions and 1 deletions
|
@ -166,8 +166,10 @@ class Site < ApplicationRecord
|
||||||
end
|
end
|
||||||
|
|
||||||
# Similar a site.i18n en jekyll-locales
|
# Similar a site.i18n en jekyll-locales
|
||||||
|
#
|
||||||
|
# @return [Hash]
|
||||||
def i18n
|
def i18n
|
||||||
data[I18n.locale.to_s]
|
data[I18n.locale.to_s] || {}
|
||||||
end
|
end
|
||||||
|
|
||||||
# Devuelve el idioma por defecto del sitio, el primero de la lista.
|
# Devuelve el idioma por defecto del sitio, el primero de la lista.
|
||||||
|
|
Loading…
Reference in a new issue