Comments (1)
Hi @ibrahima, thanks for reporting this issue.
I think this is a valid point and find_by
implementation should be changed to consider all given options, something like below.
def find_by(options)
find do |item|
options.collect do |field, value|
item.send(field).to_s == value.to_s
end.all?(true)
end
end
cc @apotonick
from disposable.
Related Issues (20)
- How to set writeable dynamically? HOT 6
- Twin::Collection can't remove members backed by a DB table with not-null constraint HOT 2
- adding/deleting from collection is not detected as change HOT 2
- The properties defined in a base class after the subclassing are missing from the subclasses.
- Nested hash field defined by external class doesn't work HOT 2
- Breaking uber changes HOT 2
- Neither #clone nor #dup produce independent Twin copies (changes to one's properties modify all copies' properties)
- Improve Dirty Tracking API HOT 4
- Travis is not passing on rubies 1.9 and 2.0 HOT 1
- Nilify true on a collection of strings HOT 2
- Private method exception using "parent" feature with reform on rails-4.2.x HOT 3
- HABTM Association causes sync() to save model. HOT 1
- Public `build_twin` method HOT 2
- Support sequel association attributes HOT 3
- Ruby 2.3.3, Rails 4.2 Disposable::Twin::Struct refers to ::Struct HOT 9
- "Reverse" sync HOT 2
- Calling destroy on populator causes 442 Unprocessable Entity error
- Module that has 'unnest' throws an error if included more than once HOT 1
- Rails default validations not catched HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from disposable.