Displaying 1 result from an estimated 1 matches for "referencig".
Did you mean:
referencing
2006 Jul 30
1
Bug? find_by_id(nil) returns object just created
...dynamic finder with an id of nil:
>> Foo.find_by_id(nil)
=> #<Foo:0x2aaaac39dca0 @attributes={"name"=>"bar", "id"=>"7"}>
Step: 3. Do the same find again:
>> Foo.find_by_id(nil)
=> nil
This only happens with any dynamic finder referencig ''id'' (i.e. find_by_id,
find_by_id_and_user_id, etc.), not with any other attribute.
I''m running Rails 1.1.4 on FC4, Mysql v. 4.1.14, Mysql-Ruby gem 2.7. It was
replicated on Rails 1.1.1 on Debian stable, Mysql v. 4.1, Debian
libmysql-ruby1.8 vs. 2.4.5-6.1.
-------------...