Skip to content

Instantly share code, notes, and snippets.

@elektronaut
Created June 19, 2015 00:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save elektronaut/98a745c68f77267a573c to your computer and use it in GitHub Desktop.
Save elektronaut/98a745c68f77267a573c to your computer and use it in GitHub Desktop.
whitelist = [:email, :password, :and_so_on]
user_params = params
.keep_if { |k, v| whitelist.include?(k) && !v.nil? }
.merge(uuid: @user.uuid)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment