Move add_to_log to class
Bump required Moodle