开发者

Devise, how to downcase emails on save?

right now users can log into devise with their email & password. Problem is that email is saved case sensitive which is confusing users.

Does Devise have a setting to downcase the email, something like downcase_keys?

I know I can manually do this with a before_save but I tho开发者_如何学Cught I had read devise had this as an option out of the box. I just can't find the doc on how to set it to downcase?

Thanks


You should be able to configure it using case_insensitive_keys in config/initializers/devise.rb (see here).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜