mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #27795 from eguven/2015.8-postgres_user-group-change
better change reporting for postgres_user groups
This commit is contained in:
commit
ec35666ff2
1 changed files with 3 additions and 2 deletions
|
@ -191,8 +191,9 @@ def present(name,
|
|||
if isinstance(groups, (six.string_types, six.text_type)):
|
||||
lgroups = lgroups.split(',')
|
||||
if isinstance(lgroups, list):
|
||||
if [a for a in lgroups if a not in user_groups]:
|
||||
update = True
|
||||
missing_groups = [a for a in lgroups if a not in user_groups]
|
||||
if missing_groups:
|
||||
update['groups'] = missing_groups
|
||||
|
||||
if mode == 'create' or (mode == 'update' and update):
|
||||
if __opts__['test']:
|
||||
|
|
Loading…
Add table
Reference in a new issue