diff --git a/plugins/modules/zabbix_host.py b/plugins/modules/zabbix_host.py index 2377a5aa6..865473f25 100644 --- a/plugins/modules/zabbix_host.py +++ b/plugins/modules/zabbix_host.py @@ -653,7 +653,7 @@ def construct_host_interfaces(self, interfaces): if interface['type'] == 1: ip = interface.get('ip', '') - if 'port' not in interface: + if 'port' not in interface or interface['port'] is None: interface['port'] = type_to_port.get(interface['type'], '') if LooseVersion(self._zbx_api_version) >= LooseVersion('5.0.0'):