forked from rails-api/rails-api
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This commit doesn't add anything since before it wrap_parameters was overriden to do nothing. Closes rails-api#33
- Loading branch information
1 parent
cdd2aac
commit 57c3bf2
Showing
2 changed files
with
16 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
lib/rails-api/templates/rails/app/config/initializers/wrap_parameters.rb.tt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# Be sure to restart your server when you modify this file. | ||
# | ||
# This file contains settings for ActionController::ParamsWrapper which | ||
# is enabled by default. | ||
|
||
# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array. | ||
# ActiveSupport.on_load(:action_controller) do | ||
# wrap_parameters format: [:json] if respond_to?(:wrap_parameters) | ||
# end | ||
|
||
<%- unless options.skip_active_record? -%> | ||
# To enable root element in JSON for ActiveRecord objects. | ||
# ActiveSupport.on_load(:active_record) do | ||
# self.include_root_in_json = true | ||
# end | ||
<%- end -%> |