Skip to content

Commit

Permalink
Update lib/adbc_connection.ex
Browse files Browse the repository at this point in the history
Co-authored-by: José Valim <[email protected]>
  • Loading branch information
cocoa-xu and josevalim authored Jun 23, 2024
1 parent ee1a56e commit f1edabe
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions lib/adbc_connection.ex
Original file line number Diff line number Diff line change
Expand Up @@ -411,12 +411,7 @@ defmodule Adbc.Connection do
Enum.zip_with(chucked_results, fn columns ->
Enum.reduce(columns, fn column, merged_column ->
merged_data =
case {is_list(merged_column.data), is_list(column.data)} do
{true, true} -> merged_column.data ++ column.data
{true, false} -> merged_column.data ++ [column.data]
{false, true} -> [merged_column.data] ++ column.data
{false, false} -> [merged_column.data] ++ [column.data]
end
List.wrap(merged_column.data) ++ List.wrap(column.data)

%{merged_column | data: merged_data}
end)
Expand Down

0 comments on commit f1edabe

Please sign in to comment.