Thanks Philip. I used something similar to your suggestion "Model.find_by_foo() || Model.get_default()". I#d rather be explicit on that.
Jens > > If it were me I'd either make it explicit in the code > "Model.find_by_foo() || Model.get_default()" or extend AR to support > find_by_xxx_or_default and then call it that way. Don't forget though > that "xxx" might also be "xxx_and_yyy_and_zzz". > > -philip -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

