MDL-62175 auth_email: Fix site policy enabled check

This commit is contained in:
Juan Leyva 2018-04-24 11:48:00 +02:00
parent 6fa694bef0
commit e709853ee6

View File

@ -293,7 +293,7 @@ class auth_email_external extends external_api {
$data['email2'] = $data['email'];
// Force policy agreed if a site policy is set. The client is responsible of implementing the interface check.
$manager = new \core_privacy\local\sitepolicy\manager();
if (!$manager->is_defined()) {
if ($manager->is_defined()) {
$data['policyagreed'] = 1;
}
unset($data['recaptcharesponse']);