-
Improvement
-
Resolution: Unresolved
-
Major
-
None
-
4.0, 4.1
-
MOODLE_400_STABLE, MOODLE_401_STABLE
Admin settings don't follow the naming conventions and settings are stored in the config table instead of config_plugins one.
Admin settings naming is not according to the rules in documentation, https://docs.moodle.org/dev/Admin_settings#Individual_settings:
$name here is 'mod_lesson/mediawidth'. The slash is important here. It indicates that this setting is owned by the mod_lesson plugin and should be stored in the config_plugins table. Settings that do not have this slash would be stored in the global config table and also exposes them via $CFG properties. Plugin-scope settings can be obtained only via get_config() call. You may notice some older plugins such as the Forum module or many blocks, still store their settings in the global config table. That is strongly discouraged for new plugins.
... new activity modules should use 'mod_mymodule/setting' instead of 'mymodule/setting' as identifier.
The main problem is the existence of settings of a previous version that will need to be migrated. Consider that could be also settings defined in config.php.