rails/rails — pull request #11064 by mokevnin (2013-06-23 18:03:13+00:00)
Title: add method 'extract' to hash

for example https://github.com/mokevnin/rails-examples/blob/develop/app/controllers/web/passwords_controller.rb

def confirm
user = User.where(params.extract(:id, :confirmation_token)).first!

i can't use method slice, since with empty params i get empty hash.