Rails omniauth - twitter asking for app authorization each time user logs in

前端 未结 7 783
情歌与酒
情歌与酒 2021-02-06 13:48

In Railscast: http://railscasts.com/episodes/241-simple-omniauth Ryan uses omniauth for logins. In the video when he clicks on the login button the first time Twitter asks the u

7条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2021-02-06 14:17

    I suspect a regression or something in the twitter oauth gem:

    EDIT: Solves the issue.

    I believe that oauth removed the individual strategies. In any case, using Devise, the following fixed this (should work as modified for other Twitter oauth configs):

    config.omniauth :twitter, 'consumer_key' , 'consumer_secret', :client_options => {:authorize_path => '/oauth/authenticate'}
    

提交回复
热议问题