Categories: None [Edit]

get_or_build

https://rubygems.org/gems/get_or_build
Assume user belongs_to company and you want to get company object within one method call. You can do it like this: user.company_or_build

Total

Ranking: 60,454 of 193,756
Downloads: 18,174

Daily

Ranking: 71,816 of 193,649
Downloads: 1

Depended by

RankDownloadsName

Depends on

RankDownloadsName
81,345,947,699rake
36801,545,420activerecord
38789,964,831actionpack
279185,971,812sqlite3

Owners

#GravatarHandle
1iconka8725