1
votes

I am using Rails 4.0.2 and Devise 3.2.2 to handle user registration / authentication. I have enabled :confirmable but was wondering if there is a way to configure :confirmable?

eg: authentication key expiry...etc

Currently, when users sign up with email address: [email protected], that email address stays taken/unavailable even when the user doesn't activate/verify that email address.

How do I configure Devise :confirmable so that the email address a user signed up with will becomes available again if the user does not activate in a period of time ?

Thanks!

2

2 Answers

1
votes

check the following link it has enough information about confirmable module

[1]https://github.com/plataformatec/devise/wiki/How-To%3a-Add-%3aconfirmable-to-Users

0
votes

I don't think the devise 'confirmable' will do that for you. However, you can use 'recoverable' to reset passwords for the account. It is very unlikely that someone different will now own an email account so your best bet is to add a "Forgot your password?" page using recoverable for your end users.

If you want to explicitly to remove the user entries, I think your best bet is to generate a rake task that checks when the user was created and that the account hasn't been confirmed. Then put that task on a cron so you run it say every night. Though I really don't see the need for it. I believe you're approaching the problem from the wrong angle, and I recommend recoverable as your approach.

Take care, and good luck!