1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

Merge pull request #1520 from minter/rackspace_domain_search

Allow selection of domains via substring
This commit is contained in:
Brian Hartsock 2013-01-28 14:34:09 -08:00
commit 027567a0dc

View file

@ -13,6 +13,15 @@ module Fog
data = service.list_domains.body['domains']
load(data)
end
# Returns all domains containing the given substring. Still limited
# by the 100-domain pagination limit. Returns an empty array if
# no matches.
def find(substring)
clear
data = service.list_domains(:name => substring).body['domains']
load(data)
end
def get(zone_id)
if zone_id.nil? or zone_id.to_s.empty?