Rename creds key email -> public_email

We had a name collision when trying to grab the GitHub user's email
address, so if the user did not have a public email address the
authentication would fail with a 500 (InvalidProfileResponse).
This commit is contained in:
Jezen Thomas 2016-07-06 21:01:15 +02:00
parent c514df2c39
commit 9d6d4b420d
No known key found for this signature in database
GPG Key ID: 5FEF410819FCBDB7

View File

@ -107,7 +107,7 @@ toCreds user userMails token = Creds
, ("access_token", decodeUtf8 $ accessToken token) , ("access_token", decodeUtf8 $ accessToken token)
] ]
++ maybeExtra "name" (githubUserName user) ++ maybeExtra "name" (githubUserName user)
++ maybeExtra "email" (githubUserPublicEmail user) ++ maybeExtra "public_email" (githubUserPublicEmail user)
++ maybeExtra "location" (githubUserLocation user) ++ maybeExtra "location" (githubUserLocation user)
} }