2011-05-06 02:38:25 +00:00
|
|
|
# Be sure to restart your server when you modify this file.
|
|
|
|
#
|
2011-07-30 15:52:38 +00:00
|
|
|
# This file contains settings for ActionController::ParamsWrapper which
|
|
|
|
# is enabled by default.
|
2011-05-06 02:38:25 +00:00
|
|
|
|
2011-07-30 15:52:38 +00:00
|
|
|
# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
|
2011-09-03 20:09:54 +00:00
|
|
|
ActiveSupport.on_load(:action_controller) do
|
|
|
|
wrap_parameters :format => [:json]
|
|
|
|
end
|
2011-05-06 02:38:25 +00:00
|
|
|
|
|
|
|
# Disable root element in JSON by default.
|
2011-09-03 20:09:54 +00:00
|
|
|
ActiveSupport.on_load(:active_record) do
|
|
|
|
self.include_root_in_json = false
|
2011-05-06 02:38:25 +00:00
|
|
|
end
|