We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Now, where(undefined_key: nil) returns all records. But I think where(undefined_key: nil) should raise an error because
where(undefined_key: nil)
class Records < ActiveHash::Base self.data = [ { id: 1, name: 'foo' }, { id: 2, name: 'bar' }, { id: 3, name: 'baz' } ] end pp Records.where(undefined_key: nil).to_a # [ # #<Records:0x00007fadaf51a5e0 @attributes={:id=>1, :name=>"foo"}>, # #<Records:0x00007fadaf519988 @attributes={:id=>2, :name=>"bar"}>, # #<Records:0x00007fadaf519348 @attributes={:id=>3, :name=>"baz"}> # ]
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Description
Now,
where(undefined_key: nil)
returns all records.But I think
where(undefined_key: nil)
should raise an error becauseCode to reproduce
Other informations
The text was updated successfully, but these errors were encountered: