mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Remove whitespace from unix group names
This commit is contained in:
parent
c8e16793bf
commit
d0e3d75381
1 changed files with 1 additions and 1 deletions
|
@ -552,7 +552,7 @@ class User(object):
|
|||
if self.groups is None:
|
||||
return None
|
||||
info = self.user_info()
|
||||
groups = set(filter(None, self.groups.split(',')))
|
||||
groups = set([x.strip() for x in self.groups.split(',') if x])
|
||||
for g in set(groups):
|
||||
if not self.group_exists(g):
|
||||
self.module.fail_json(msg="Group %s does not exist" % (g))
|
||||
|
|
Loading…
Reference in a new issue