lib/uncharted.rb in uncharted-0.0.9 vs lib/uncharted.rb in uncharted-0.0.10

- old
+ new

@@ -1,15 +1,21 @@ # encoding: utf-8 -require 'uncharted/i18n' +require 'i18n' require 'uncharted/country' require 'uncharted/territory' -require 'uncharted/data/countries' -require 'uncharted/data/br' - require 'uncharted/extensions/mongoid' require 'uncharted/extensions/rails' -Country = Uncharted::Country -Territory = Uncharted::Territory + +# Load ISO 3166 country and territory lists +require 'uncharted/config/countries' +require 'uncharted/config/br' + +# Load default locales +I18n.load_path += Dir["#{File.dirname(__FILE__)}/uncharted/config/locales/*.yml"] + +# Use shortcut if classes are not already defined +Country = Uncharted::Country unless defined?(Country) +Territory = Uncharted::Territory unless defined?(Territory) \ No newline at end of file