From 5c05016d1ee704ecf2ac307ace878a028d6faaa4 Mon Sep 17 00:00:00 2001 From: Dominique Barton Date: Tue, 24 Nov 2015 11:40:03 +0100 Subject: [PATCH] bugfix for issue #2537 --- lib/ansible/modules/system/user.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/ansible/modules/system/user.py b/lib/ansible/modules/system/user.py index 17aad879e32..919d6fd51ff 100755 --- a/lib/ansible/modules/system/user.py +++ b/lib/ansible/modules/system/user.py @@ -1683,7 +1683,8 @@ class DarwinUser(User): out = '' err = '' - self._make_group_numerical() + if self.group: + self._make_group_numerical() for field in self.fields: if self.__dict__.has_key(field[0]) and self.__dict__[field[0]]: