naomiquirke / moodle-mod_cado

Moodle module to generate a course curriculum automatically, compare courses, and enable a course approval workflow within Moodle.
GNU General Public License v3.0
0 stars 0 forks source link

inline functions mixed in with a class #10

Closed danmarsden closed 4 years ago

danmarsden commented 4 years ago

https://github.com/naomiquirke/moodle-mod_cado/blob/master/classes/check.php#L29

This file shouldn't include in-line functions and should just have the class mod_cado_check

I see you use the same functions in the cado.php file - you could either drop these functions into one of your classes, or as inline functions in your lib.php - but also be aware that in-line functions must use the frankenstyle prefix to avoid conflicts.

Modules are treated slightly differently in that you are allowed to use the module name as a prefix eg: cado_sorter but mod_cato_sorter is also allowed.

This one is a blocker for plugins db approval.

naomiquirke commented 4 years ago

Thanks for the advice, Dan. This has been fixed in version 1.1.