- Changed some string functions from unibyte to multibyte
- Some code and comment cleaning
- Some migration of SQL to Moodle's API best choices
- Some deprecated methods changed (context)