Facebook auth without an email should allow user to enter email

In some cases Facebook doesn't send back a user's email. In this
case, allow the user to enter their email address.

See
https://meta.discourse.org/t/facebook-initial-login-create-account-dialog-leaves-email-field-blank/13815/15
This commit is contained in:
Greg Kempe 2014-12-08 12:40:44 +02:00
parent 3547c20aa7
commit e979382ab4

View File

@ -12,7 +12,7 @@ class Auth::FacebookAuthenticator < Auth::Authenticator
facebook_hash = session_info[:facebook]
result.email = email = session_info[:email]
result.email_valid = true
result.email_valid = !email.blank?
result.name = facebook_hash[:name]
result.extra_data = facebook_hash