Merge pull request #50785 from JunichiIto/add-note-to-params-hash

Add note about `params` hash in Action Controller Overview [ci skip]
This commit is contained in:
Petrik de Heus 2024-06-04 14:52:10 +02:00 committed by GitHub
commit 5ade5d4173
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 0 deletions

View File

@ -110,7 +110,10 @@ class ClientsController < ApplicationController
end
```
NOTE: The `params` hash is not a plain old Ruby Hash; instead, it is an [`ActionController::Parameters`][] object. While it behaves like Hash, it does not inherit from Hash.
[`params`]: https://api.rubyonrails.org/classes/ActionController/StrongParameters.html#method-i-params
[`ActionController::Parameters`]: https://api.rubyonrails.org/classes/ActionController/Parameters.html
### Hash and Array Parameters