Skip to content

Commit 8a80d11

Browse files
committed
(Rubo) Rubocop Fix
1 parent f0ced3d commit 8a80d11

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/puppet/provider/firewall/firewall.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,8 @@ def insync?(context, _name, property_name, is_hash, should_hash)
432432
should.each_with_index do |_value, _index|
433433
should = should.map { |value| value.to_s.tr('! ', '') }.sort
434434
# Port range can be passed as `-` but will always be set/returned as `:`
435-
should = should.map { |value| value.to_s.tr('-', ':') }.sort if [:dport, :sport].include?(property_name)
435+
ports = [:dport, :sport]
436+
should = should.map { |value| value.to_s.tr('-', ':') }.sort if ports.include?(property_name)
436437
end
437438
should[0] = ['!', should[0]].join(' ') if should_negated
438439

0 commit comments

Comments
 (0)