usb_cables: fix generator script
This commit is contained in:
parent
f31fd6052d
commit
aa6bb0ace7
|
@ -45,7 +45,7 @@ cables.each_index do |i|
|
|||
next if 0 == i
|
||||
cable = cables[i]
|
||||
# find if there was a previously matching definition
|
||||
template = cables[0, (i-1)].filter {|c| c[:name] == cable[:name]}.first
|
||||
template = cables[0, i].filter {|c| c[:name] == cable[:name]}.first
|
||||
next unless template
|
||||
puts "generate #{cable[:variable]} usng #{template[:variable]}"
|
||||
array = template[:array]
|
||||
|
|
Loading…
Reference in New Issue