Permalink
Browse files

Switch default CLDR download to latest, fix export

  • Loading branch information...
Cameron Dutro
Cameron Dutro committed May 24, 2012
1 parent 4486478 commit acc9a2a4672f65ca933817313b47e143c9fc78de
Showing with 6 additions and 2 deletions.
  1. +1 −1 lib/cldr/download.rb
  2. +5 −1 lib/cldr/export.rb
View
@@ -6,7 +6,7 @@
module Cldr
class << self
def download(source = nil, target = nil)
- source ||= 'http://unicode.org/Public/cldr/1.7.2/core.zip'
+ source ||= 'http://unicode.org/Public/cldr/21/core.zip'
target ||= File.expand_path('./vendor/cldr')
source = URI.parse(source)
View
@@ -43,7 +43,11 @@ def data(component, locale, options = {})
else
data = locales(locale, options).inject({}) do |result, locale|
data = Data.const_get(component.to_s.camelize).new(locale)
- data ? data.deep_merge(result) : result
+ if data
+ data.is_a?(Hash) ? data.deep_merge(result) : data
+ else
+ result
+ end
end
# data = resolve_links if options[:merge] TODO!!
data

0 comments on commit acc9a2a

Please sign in to comment.