Sha256: 928091f61017aebb3624f77e3d8f0047ed19b66f72851f972dcb79a5d3fac093
Contents?: true
Size: 719 Bytes
Versions: 6
Compression:
Stored size: 719 Bytes
Contents
# frozen_string_literal: true require_relative "countries_regions_and_cities_by_pete/version" require 'carmen' require 'city-state' module CountriesRegionsAndCitiesByPete # require 'countries_regions_and_cities_by_peterconsuegra/railtie' if defined?(Rails) class Error < StandardError; end # Your code goes here... def self.get_all_countries return Carmen::Country::all end def self.get_regions(selected_country) country = Carmen::Country.coded(selected_country) return country.subregions if country end def self.get_cities(selected_region,selected_country) CS.cities(selected_region,selected_country) end end require_relative "railtie" if defined?(Rails::Railtie)
Version data entries
6 entries across 6 versions & 1 rubygems