Skip to content

Instantly share code, notes, and snippets.

@universal
Created June 12, 2015 10:26
Show Gist options
  • Save universal/4a9738ac0102c28a88ab to your computer and use it in GitHub Desktop.
Save universal/4a9738ac0102c28a88ab to your computer and use it in GitHub Desktop.
raw_params =
{:user=>
{:a=>"a",
:b=>
[{:c=>"c", :d=>"d"},
{:c=>"c", :d=>"d"},
{:c=>"c", :d=>"d"},
{:c=>"c", :d=>"d"},
{:c=>"c", :d=>"d"}]}}
params = ActionController::Parameters.new(raw_params)
params.require(:user).permit(:a, b: [:c])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment