Bug #9582 ยป 9582.patch
ChangeLog | ||
---|---|---|
Wed Mar 5 13:49:20 2014 Thiago Lewin <thiago_lewin@yahoo.com.br>
|
||
* lib/pathname.rb (CSV::Table#headers): search for the first
|
||
row with header.
|
||
[ruby-core:61154]
|
||
Wed Mar 5 11:58:30 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||
* ext/openssl/ossl.c (ossl_make_error): check NULL for unknown
|
lib/csv.rb | ||
---|---|---|
if @table.empty?
|
||
Array.new
|
||
else
|
||
@table.first.headers
|
||
# search for the first row with headers
|
||
@table.each do |row|
|
||
row_headers = row.headers
|
||
return row_headers unless row_headers.empty?
|
||
end
|
||
Array.new
|
||
end
|
||
end
|
||