Array.to_h not supported in Ruby < 2.1