Skip to content

Commit 64b2d53

Browse files
author
Davide Ferrari
committed
Use empty method to check arrays
1 parent 680d15c commit 64b2d53

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

templates/zone-master.erb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ zone "<%= @name %>" IN {
1717
allow-transfer { none; };
1818
<% end -%>
1919
<% if @is_dynamic -%>
20-
allow-update { <% if ![nil, '', :undef].include?(@allow_update) -%>key <%= Array(@allow_update).join('.; key ') -%>.;<% end
21-
-%><% if ![nil, '', :undef].include?(@allow_update_cidr) -%> <%= Array(@allow_update_cidr).join('; ') -%>;<% end -%> };
20+
allow-update { <% if !@allow_update.empty? -%>key <%= Array(@allow_update).join('.; key ') -%>.;<% end
21+
-%><% if !@allow_update_cidr.empty? -%> <%= Array(@allow_update_cidr).join('; ') -%>;<% end -%> };
2222
<% end -%>
2323
allow-query { any; };
2424
notify yes;

0 commit comments

Comments
 (0)