Skip to content

Commit

Permalink
Merge pull request #484 from sparklemotion/faster-hash
Browse files Browse the repository at this point in the history
Don't flatten row array before passing to Hash#[]
  • Loading branch information
tenderlove committed Jan 24, 2024
2 parents f5f6859 + 13a5e35 commit 74763cb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/sqlite3/resultset.rb
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def next_hash
row = @stmt.step
return nil if @stmt.done?

Hash[*@stmt.columns.zip(row).flatten]
@stmt.columns.zip(row).to_h
end
end

Expand Down

0 comments on commit 74763cb

Please sign in to comment.