<?php

namespace api\classes;

use api\classes\API;

require_once 'API.php';

class API_resetpassword extends API
{
    public function resetPassword()
    {

        $query = "UPDATE system_users SET user_password = ?,  user_password_reset_token = ?, user_password_reset_expires = ? WHERE user_uuid = ?";
        $stmt = $this->prepareStatement($query);
        $stmt->bind_param("ssis",
            $this->data['user_password'],
            $this->data['user_password_reset_token'],
            $this->data['user_password_reset_expires'],
            $this->data['user_uuid']
        );

        $this->executeStatement($stmt);

    }
}