update to work in moodle 2.5