-
Notifications
You must be signed in to change notification settings - Fork 109
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
Conflict on the EmailValidator with another gem (devise_token_auth) #46
Comments
Sorry, i completely forgot to attend to this issue. I'm open to move |
This is a breaking change. The invocation changes from: validates :email, email: true to validates :email, email2: true This solves micke#46
This is a breaking change. The invocation changes from: validates :email, email: true to validates :email, 'valid_email_2/email': true This solves micke#46
This is a breaking change. The invocation changes from: validates :email, email: true to validates :email, 'valid_email_2/email': true This solves micke#46
Looks like this issue can now be closed :) |
I just pushed v2.0.0 to rubygems which includes @fredngo's pr which namespaces the validator. |
under rails 5 and use devise, I put |
@andystu Are you sure you are running version 2.0.0? |
Steps to reproduce with rails 5:
Add to Gemfile:
create app/model/invitation.rb
The problem seems to be that devise_token_auth also has an EmailValidator which overwrites valid_email2's validator.
Is there a way to force to use valid_email2 and not devise_token_auth?
I've tried to change the gemfile with
and adding
require 'valid_email2
afterBundler.require(*Rails.groups)
inconfig/application.rb
but still loads the wrong oneThe text was updated successfully, but these errors were encountered: