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: 59,617 of 191,391
Downloads: 18,023

Daily

Ranking: 56,244 of 191,335
Downloads: 4

Depended by

RankDownloadsName

Depends on

RankDownloadsName
81,271,034,194rake
36769,358,067activerecord
37758,197,354actionpack
278177,123,484sqlite3

Owners

#GravatarHandle
1iconka8725