lib/rundock/attribute/node_attribute.rb in rundock-1.0.6 vs lib/rundock/attribute/node_attribute.rb in rundock-1.0.7
- old
+ new
@@ -8,19 +8,19 @@
attr_accessor :cwd
attr_accessor :sudo
attr_accessor :dry_run
attr_accessor :hooks
- AVAIL_TAKE_OVERS = [
- :task_info,
- :errexit,
- :cwd,
- :sudo,
- :dry_run
+ AVAIL_TAKE_OVERS = %i[
+ task_info
+ errexit
+ cwd
+ sudo
+ dry_run
]
def init_except_take_over_state
- list.each do |k, _v|
+ list.each_key do |k|
define_attr(k, nil) unless AVAIL_TAKE_OVERS.include?(k)
end
end
end
end