diff --git a/states/nftables/blacklist.nft.j2 b/states/nftables/blacklist.nft.j2 index 20b0690..2eaf40f 100644 --- a/states/nftables/blacklist.nft.j2 +++ b/states/nftables/blacklist.nft.j2 @@ -1,7 +1,7 @@ ## {{ salt['pillar.get']('salt_managed', default='Salt Managed') }} {% set blackips = salt["bl.get_ips"]() %} -{% if len(blackips) > 0 %} +{% if blackips|length > 0 %} define blacklist = { {{ blackips.join(",") }} } {% else %} define blacklist = { 127.255.255.255 }