Hi,
I’ve got a model with the following attribute added:
attr_accessor :level
which does not exist in the database. After putting instances of this
model in the cache (using Rails.cache.fetch(‘foo’) { Category.all } ),
when I retrieve it back from the cache, then trying to access .level
gives:
undefined method `level’ for #Category:0x34d50a0
I’m simply using the memorystore. In script/console it works fine,
just not when in script/server. Anybody knows what’s happening here?
Best regards,
Jimmy