From 02609240031aabef16fc8e182d41d556c0894c24 Mon Sep 17 00:00:00 2001 From: Henk Hesselink Date: Fri, 5 Mar 2021 18:21:48 -0800 Subject: [PATCH] apply prev. __class__ fix everywhere --- snmp/files/snmpd.conf | 2 +- snmp/files/snmpd.conf.minimal | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/snmp/files/snmpd.conf b/snmp/files/snmpd.conf index 7bfef37..36c8927 100644 --- a/snmp/files/snmpd.conf +++ b/snmp/files/snmpd.conf @@ -510,7 +510,7 @@ createUser {{ user.username }} {{ user.get('authproto', 'MD5') }} {{ user.get('a {%- endfor %} {% for declaration, values in config.items() %} -{%- if values.__class__ in (().__class__, [].__class__) %} +{%- if values is sequence and values is not mapping and values is not string %} {%- for value in values %} {{declaration}} {{value}} {%- endfor %} diff --git a/snmp/files/snmpd.conf.minimal b/snmp/files/snmpd.conf.minimal index f185ed3..b596b0d 100644 --- a/snmp/files/snmpd.conf.minimal +++ b/snmp/files/snmpd.conf.minimal @@ -83,7 +83,7 @@ createUser {{ user.username }} {{ user.get('authproto', 'MD5') }} {{ user.passph # Extra settings {% for declaration, values in config.items() %} -{%- if values.__class__ in (().__class__, [].__class__) %} +{%- if values is sequence and values is not mapping and values is not string %} {%- for value in values %} {{declaration}} {{value}} {%- endfor %}