Sha256: 6717e0b3ad647853029102a7acae944591f4920d7ba1ae68c46c19cb81ec6d45
Contents?: true
Size: 336 Bytes
Versions: 9
Compression:
Stored size: 336 Bytes
Contents
require 'httparty' require 'ipaddress' module Moocher module Ip def ip_blacklisted?(ipaddress) return "IP Address doesn't seem to be valid." if !(IPAddress.valid? ipaddress) base_url = 'https://api.moocher.io/badip/IPV4/' response = HTTParty.get(base_url + ipaddress) response.success? end end end
Version data entries
9 entries across 9 versions & 1 rubygems