return unique list of hosts

pull/13451/head
Brian Coca 9 years ago
parent 46718ac3f4
commit c03b8ef0c2

@ -196,7 +196,7 @@ class Inventory(object):
hosts = [ h for h in hosts if h in self._restriction ] hosts = [ h for h in hosts if h in self._restriction ]
HOSTS_PATTERNS_CACHE[pattern_hash] = hosts[:] HOSTS_PATTERNS_CACHE[pattern_hash] = hosts[:]
return hosts return list(set(hosts))
@classmethod @classmethod
def split_host_pattern(cls, pattern): def split_host_pattern(cls, pattern):

Loading…
Cancel
Save