mirror of
https://github.com/ditkrg/active_model_serializers.git
synced 2026-01-22 22:06:50 +00:00
Merge pull request #1732 from remear/jsonapi-renderer
Include ControllerSupport on ActiveSupport on_load action_controller
This commit is contained in:
commit
9f59398f2b
@ -60,4 +60,6 @@ ActionController::Renderers.add :jsonapi do |json, options|
|
||||
self.response_body = json
|
||||
end
|
||||
|
||||
ActionController::Base.send :include, ActiveModelSerializers::Jsonapi::ControllerSupport
|
||||
ActiveSupport.on_load(:action_controller) do
|
||||
include ActiveModelSerializers::Jsonapi::ControllerSupport
|
||||
end
|
||||
|
||||
Loading…
Reference in New Issue
Block a user