Tried the following
def pkill(process_name, *host)
puts host.nil? # => false
puts host.empty? # => true
puts host # => nil
puts host[0].nil? # => true
end
Now if I call send("pkill", blah, nil), how/why is host false??
Pretty new to ruby, so keep it smooth 🙂
Because it’s not nil, it’s empty array.