ovirt_network: ovirt fix getting labels (#52499)

* ovirt fix getting labels

* add changelog - ovirt_network_label_fail

* add new line to changelog ovirt_network_label_fail
pull/52601/head
Martin Nečas 6 years ago committed by ansibot
parent da77057566
commit 8d5811a611

@ -0,0 +1,2 @@
bugfixes:
- ovirt_network - fix getting network labels (https://github.com/ansible/ansible/pull/52499).

@ -184,8 +184,8 @@ class NetworksModule(BaseModule):
if self.param('label') is None:
return
labels = [lbl.id for lbl in self._connection.follow_link(entity.network_labels)]
labels_service = self._service.service(entity.id).network_labels_service()
labels = [lbl.id for lbl in labels_service.list()]
if not self.param('label') in labels:
if not self._module.check_mode:
if labels:

Loading…
Cancel
Save