rails devise, no route matches logout

后端 未结 3 439
终归单人心
终归单人心 2021-01-02 03:53

Though there\'re lots of similar questions, i\'ve searched for it for hours but still can not fix it.

Env rails 3.0.9 ruby 1.9.2 devise 1.4.2

I changed the d

3条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-01-02 04:51

    Set config.sign_out_via = :get in config/initializers/devise.rb to use the following code for your sign out link.

    <%= link_to "Sign Out", destroy_user_session_path %>
    

提交回复
热议问题