mirror of
https://github.com/ditkrg/active_model_serializers.git
synced 2026-01-24 23:06:50 +00:00
Handle inflecting api to s/API/Api without side-effects
This commit is contained in:
parent
506739d4fb
commit
4359026c0e
@ -33,7 +33,8 @@ module ActiveModel
|
|||||||
end
|
end
|
||||||
|
|
||||||
def self.adapter_class(adapter)
|
def self.adapter_class(adapter)
|
||||||
"ActiveModel::Serializer::Adapter::#{adapter.to_s.classify}".safe_constantize
|
adapter_name = adapter.to_s.classify.sub("API", "Api")
|
||||||
|
"ActiveModel::Serializer::Adapter::#{adapter_name}".safe_constantize
|
||||||
end
|
end
|
||||||
|
|
||||||
def fragment_cache(*args)
|
def fragment_cache(*args)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user