Here's an example:
class LineItem < ActiveRecord::Base
class Order < ActiveRecord::Base
my_line_item = LineItem.find(:zipcode => "12345")
Order.find_by_line_item(my_line_item) # doesn't work
Order.find_by_line_item_id (my_line_item) # does work
I was surprised by this, because it seems to force me to make reference
to the id field of the line item, rather than referring to the LineItem
as a class or type in the Order.findxxx statement.
Am I misunderstanding something or missing a trick?