Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inheritance of serializer does not inherits the cache! #1219

Closed
passalini opened this issue Oct 1, 2015 · 2 comments · Fixed by #1249
Closed

Inheritance of serializer does not inherits the cache! #1219

passalini opened this issue Oct 1, 2015 · 2 comments · Fixed by #1249

Comments

@passalini
Copy link

I'm on 0.10.0.rc3 and when I do a serializer inheritance the child does not inherits the parent's cache config.. Is this expected or an issue?

Expected or not, I think that it needs some doc.

@bf4
Copy link
Member

bf4 commented Oct 2, 2015

Right now it is expected since it's a class method, not a class_attribute. We could try a pr that changes

class << self
  attr_accessor :_cache #and whatever other
end

to

class_attribute :_cache, instance_writer: false, instance_reader: false

pr?

@passalini
Copy link
Author

👍 It will be nice!

I tried to put this code in Gem's Serializer but just it does not work or I put it in the wrong place.. Right now I'm a little busy with russian dolls to spend more time with it, but when I finish it I will try to do your ideia work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants