-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow Database#get to take an array to return multiple values, simila…
…r to map/select_map This is very similar to the map/select_map change made some time go. For array arguments, we need to make sure we have a valid alias for each array element, then we just use values_at to retrieve the resulting values. This could potentially cause backwards compat issues when using a conditions specifier: DB.get([[:a, 1], [:b, 2]]) That type of code now needs to be updated: DB.get(Sequel.expr([[:a, 1], [:b, 2]])) The same was true of the map/select_map change, but I didn't realize the backwards compat issues back then. However, as nobody reported problems, it's unlikely anyone was relying on the old behavior.
- Loading branch information
1 parent
1c82ae2
commit a0d5ffa
Showing
3 changed files
with
62 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters