Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QUESTION: tokens field in database #763

Closed
sarbull opened this issue Nov 4, 2016 · 2 comments
Closed

QUESTION: tokens field in database #763

sarbull opened this issue Nov 4, 2016 · 2 comments

Comments

@sarbull
Copy link

sarbull commented Nov 4, 2016

What happens with the token field in the users table in the database?

  • After each login it gets bigger and bigger?
  • It's deleted on expiration date?

Can you please explain?

@lovesmall
Copy link

Yes, seems it will grow up to the max number then delete the oldest. From the config file devise_token_auth.rb :

  # Sets the max number of concurrent devices per user, which is 10 by default.
  # After this limit is reached, the oldest tokens will be removed.
  # config.max_number_of_devices = 10

You can find how it exactly worked at devise_token_auth/app/models/devise_token_auth/concerns/user.rb

@zachfeldman
Copy link
Contributor

Possible answer posted by @lovesmall , closing for now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants