Dalia William
Dalia William

Reputation: 89

Problems while installing devise

After I installed the gem devise .. when I try to run the server .. this is what I get

DEVISE] Devise.case_insensitive_keys is false which is no longer supported. Recent Devise versions automatically downcase the e-mail before saving it to the database but your app isn't using this feature. You can solve this issue by either:

1) Setting config.case_insensitive_keys = [:email] in your Devise initializer and running a migration that will downcase all emails already in the database;

2) Setting config.case_insensitive_keys = [] (so nothing will be downcased) and making sure you are not using Devise :validatable (since validatable assumes caseinsensitivity)

[DEVISE] Devise.apply_schema is true. This means Devise was automatically configuring your DB. This no longer happens. You should set Devise.apply_schema to false and manually set the fields used by Devise as shown here: https://github.com/plataformatec/devise/wiki/How-To:-Upgrade-to-Devise-2.0-migration-schema-style

[DEVISE] Devise.use_salt_as_remember_token is false which is no longer supported. Devise now only uses the salt as remember token and the remember_token column can be removed from your models.

[DEVISE] Devise.reset_password_within is nil. Please set this value to an interval (for example, 6.hours) and add a reset_password_sent_at field to your Devise models (if they don't have one already).

Any Help??

Upvotes: 0

Views: 449

Answers (1)

cutalion
cutalion

Reputation: 4394

Run rails g devise:install.

It will generate config/initializers/devise.rb file with all these settings.

Upvotes: 1

Related Questions