21 lines
424 B
PHP
21 lines
424 B
PHP
<?php
|
|
|
|
include __DIR__.'/account.php';
|
|
|
|
/**
|
|
* Restores the user password.
|
|
*/
|
|
class RestorePassword extends Vn\Web\JsonRequest {
|
|
const PARAMS = ['verificationToken', 'newPassword'];
|
|
|
|
function run($db) {
|
|
$verificationToken = $_REQUEST['verificationToken'];
|
|
$newPassword = $_REQUEST['newPassword'];
|
|
|
|
$db->query('CALL account.myUser_restorePassword(#, #)',
|
|
[$verificationToken, $newPassword]);
|
|
return TRUE;
|
|
}
|
|
}
|
|
|