Combü Version 3.2.0
I'm implementing an extra check if a user forgets their password and wants to request a reset. To do this, I'm trying to confirm that the user knows what email address is associated with the account they wish to reset:
public string username; // set via an InputField
public string verificationEmailAddress; // set via an InputField
public void VerifyEmail()
{
User.Load(username, (User user) =>
{
if (user != null && user.email == verificationEmailAddress)
{
// User email verification success
}
}
}
Here "user.email" always returns an empty string, which makes verification impossible (obviously all users are required to register their accounts with an email address).
I originally tried to use User.Exists() as the documentation states "Verify if it exists an account with the specified username and email." but it turns out this is really an "or" check rather than an "and", which is not helpful in this particular case.
Any assistance that can be rendered would be greatly appreciated!
Edit /vendor/skaredcreations/combu/combu/Account.php and delete line 635 (unset($array["Email"]);
), this change will be added to the next update as well.
FRANCESCO CROCETTI @ SKARED CREATIONS
Perfect, it's working as expected now. Thank you for your quick reply!