secret
Created

  • Download Gist
oauth_account.rb
Ruby
1 2 3 4 5 6 7 8 9
def oauth_account
if TwitterOauthSetting.find_by_user_id(current_user.id).nil?
@request_token = session[:request_token]
@access_token = @request_token.get_access_token(:oauth_verifier => params["oauth_verifier"])
TwitterOauthSetting.create(atoken: @access_token.token, asecret: @access_token.secret, user_id: current_user.id)
update_user_account()
end
redirect_to "/twitter_profile"
end

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.