mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 05:42:50 +00:00
Fix using DNF group upgrade/remove api
This commit is contained in:
committed by
Toshio Kuratomi
parent
8643e9cb34
commit
119c9e5d6e
@@ -399,7 +399,7 @@ def ensure(module, base, state, names, autoremove):
|
||||
for group in groups:
|
||||
try:
|
||||
try:
|
||||
base.group_upgrade(group)
|
||||
base.group_upgrade(group.id)
|
||||
except dnf.exceptions.CompsError:
|
||||
# If not already installed, try to install.
|
||||
base.group_install(group.id, dnf.const.GROUP_PACKAGE_TYPES)
|
||||
@@ -433,7 +433,7 @@ def ensure(module, base, state, names, autoremove):
|
||||
|
||||
for group in groups:
|
||||
try:
|
||||
base.group_remove(group)
|
||||
base.group_remove(group.id)
|
||||
except dnf.exceptions.CompsError:
|
||||
# Group is already uninstalled.
|
||||
pass
|
||||
|
||||
Reference in New Issue
Block a user