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:
commit
027567a0dc
1 changed files with 9 additions and 0 deletions
|
@ -14,6 +14,15 @@ module Fog
|
|||
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?
|
||||
return nil
|
||||
|
|
Loading…
Reference in a new issue