如何使用巫术找到登录用户?

时间:2014-07-16 06:59:36

标签: ruby-on-rails-3 sorcery

有没有办法找到当前登录的用户并使用巫术删除特定用户的会话?

提前致谢。

1 个答案:

答案 0 :(得分:0)

来自documentation

Below is a summary of the library methods. Most method names are self explaining and the rest are commented:

# activity logging
current_users

您可以使用current_users来遍历所有用户。要注销它们,请查看reset_session