lib/i18n/backend/helpers.rb in i18n-0.3.5 vs lib/i18n/backend/helpers.rb in i18n-0.3.6.pre
- old
+ new
@@ -36,10 +36,10 @@
def escape_default_separator(key, separator=nil)
key.to_s.tr(separator || I18n.default_separator, SEPARATOR_ESCAPE_CHAR)
end
def unescape_default_separator(key, separator=nil)
- key.to_s.tr(SEPARATOR_ESCAPE_CHAR, separator || I18n.default_separator)
+ key.to_s.tr(SEPARATOR_ESCAPE_CHAR, separator || I18n.default_separator).to_sym
end
# Expand keys chained by the the given separator through nested Hashes
# >> { "a.b.c" => "d", "a.b.e" => "f", "a.g" => "h", "i" => "j" }.unwind
# => { "a" => { "b" => { "c" => "d", "e" => "f" }, "g" => "h" }, "i" => "j"}