Add password reset request endpoint to authentication routes; update OpenAPI spec and improve user email handling in users_o
This commit is contained in:
@@ -157,6 +157,14 @@ class users_o extends db
|
||||
$this->add($customer_number, '', 0);
|
||||
// Nullify the password
|
||||
$this->password->nullify();
|
||||
// If the customer has an email address, save it
|
||||
if (isset($customer_data->email)) {
|
||||
$this->email->set($customer_data->email);
|
||||
}
|
||||
// If the customer has a name, save it as the display name
|
||||
if (isset($customer_data->name)) {
|
||||
$this->display_name->set($customer_data->name);
|
||||
}
|
||||
}
|
||||
}
|
||||
// Else return false
|
||||
|
||||
Reference in New Issue
Block a user