<% if @chains -%>
<Plugin iptables>
<%   @chains.each_pair do |table,chains|
       Array(chains).each do |chain| -%>
  Chain <%= table %> <%= chain %>
<%     end
     end -%>
</Plugin>
<% end -%>

<% if @chains -%>
<Plugin iptables>
<%   @chains.each_pair do |table,chains|
       Array(chains).each do |chain| -%>
  Chain <%= table %> <%= chain %>
<%     end -%>
<%   end -%>
</Plugin>
<% end -%>

Use separate tags for each line of code
Use separate tags for each line of code
