Created
March 24, 2012 20:50
-
-
Save rafaelp/2187647 to your computer and use it in GitHub Desktop.
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
# Ao invés de fazer isso: | |
def do_action(hashed_code = vendor.hashed_code) | |
get :edit, invite_id: hashed_code | |
end | |
# Vamos fazer isso: | |
def do_action(params = {}) | |
get :edit, {invite_id: vendor.hashed_code}.merge(params) | |
end |
Assim blz.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Acho que tem que ser um reverse merge então né?