Sha256: 6cb9744168ced0e75dd678650423132dd83e51b8df4f8d80e51caf8d16fc0444
Contents?: true
Size: 367 Bytes
Versions: 15
Compression:
Stored size: 367 Bytes
Contents
module WorldFlags module Helper module Geo def self.ip_json require "httparty" HTTParty.get('http://freegeoip.net/json/') end def self.ip_country_code @ip_country_code ||= ip_json.parsed_response['country_code'] end def ip_country_code WorldFlags::Helper::Geo.ip_country_code end end end end
Version data entries
15 entries across 15 versions & 1 rubygems