mirror of
https://github.com/ditkrg/active_model_serializers.git
synced 2026-01-25 07:16:49 +00:00
@@ -19,6 +19,7 @@ module ActiveModel
|
||||
attr_accessor :_cache_only
|
||||
attr_accessor :_cache_except
|
||||
attr_accessor :_cache_options
|
||||
attr_accessor :_cache_digest
|
||||
end
|
||||
|
||||
def self.inherited(base)
|
||||
@@ -26,6 +27,8 @@ module ActiveModel
|
||||
base._attributes_keys = {}
|
||||
base._associations = {}
|
||||
base._urls = []
|
||||
serializer_file = File.open(caller.first[/^[^:]+/])
|
||||
base._cache_digest = Digest::MD5.hexdigest(serializer_file.read)
|
||||
end
|
||||
|
||||
def self.attributes(*attrs)
|
||||
|
||||
Reference in New Issue
Block a user