spree/spree — pull request #4012 by huoxito (2013-11-24 04:44:09+00:00)
Title: Don't override accessor if method has attr as column

Say users want to add a `name` column in spree_variants. They can't make
use of that attr on a variant instance because Spree would always
delegate that method to a product.

Now it would only delegate if the model doesn't have that column. That
would be all cases in a default scenario.

Possible bad side effects: we're touching the database one more time
when booting the spree engine. That's another issue for heroku users
right now.

Opening this one as a possible suggestion / fix for that use case. Wanted to hear if there's any other better idea or maybe if the use case itself is a bad idea and we shouldn't allow it at all in Spree core. Not really sure what I think about it yet.