Commit 2019d32b authored by Evan Prodromou's avatar Evan Prodromou

let other validity checks go through first

parent 55ebddb5
......@@ -52,8 +52,9 @@ class DomainWhitelistPlugin extends Plugin
return true;
}
function onStartValidateUserEmail($user, $email, &$valid)
function onEndValidateUserEmail($user, $email, &$valid)
{
if ($valid) { // it's otherwise valid
if (!$this->matchesWhitelist($email)) {
$whitelist = $this->getWhitelist();
if (count($whitelist) == 1) {
......@@ -65,6 +66,7 @@ class DomainWhitelistPlugin extends Plugin
}
throw new ClientException($message);
}
}
return true;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment