. namespace core_xapi\task; /** * A scheduled task to clear up old xAPI state data. * * @package core_xapi * @since Moodle 4.2 * @copyright 2022 Ferran Recio * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later */ class state_cleanup_task extends \core\task\scheduled_task { /** * Get a descriptive name for this task (shown to admins). * * @return string */ public function get_name() { return get_string('xapicleanup', 'xapi'); } /** * Run task. */ public function execute() { \core_xapi\api::execute_state_cleanup(); } }