小编Sou*_*abh的帖子

使用设计令牌身份验证的问题

我目前在我的rails应用程序中使用Devise.我想用我的api添加Devise Token Auth进行身份验证.当我尝试使用设置devise_token_auth时

rails g devise_token_auth:install User auth

rake db:migrate
Run Code Online (Sandbox Code Playgroud)

我收到以下错误:

~/workspace (devise_token_auth) $ rake db:migrate --trace
** Invoke db:migrate (first_time)
** Invoke environment (first_time)
** Execute environment
rake aborted!
ArgumentError: Invalid route name, already in use: 'new_user_session' 
You may have defined two routes with the same name using the `:as` option, or you may be overriding a route already defined by a resource with the same naming. For the latter, you can restrict the routes created with `resources` as …
Run Code Online (Sandbox Code Playgroud)

authentication ruby-on-rails token devise

1
推荐指数
1
解决办法
693
查看次数

标签 统计

authentication ×1

devise ×1

ruby-on-rails ×1

token ×1