-
Bug
-
Resolution: Fixed
-
Minor
-
3.6, 3.7.3, 3.8
-
MOODLE_36_STABLE, MOODLE_37_STABLE, MOODLE_38_STABLE
-
MOODLE_37_STABLE, MOODLE_38_STABLE
-
master_
MDL-63795_core_setting_defaults -
MDL-62777 appears to have caused some core settings, and those of some 3rd party plugins, to no longer be set.
As far as core goes - tool_mobile no longer has several settings set.
This appears to be caused by some of the settings being wrapped in a IF check, that stops the settings nodes even existing prior to that setting being enabled.
Pre MDL-62777
- tool_mobile settings start with `enablemobilewebservice` unset, with a default of `1` and several settings that never get loaded until that is set.
- admin_apply_default_settings called
- settings as they currently exist loaded
- defaults set
- admin_apply_default_settings called again
- new settings now exist as `!empty($CFG->enablemobilewebservice` evaluates to true
- defaults for those new settings are set
Post MDL-62777
- tool_mobile settings start with `enablemobilewebservice` unset, with a default of `1` and several settings that never get loaded until that is set.
- admin_apply_default_settings called
- settings as they currently exist loaded
- for each of those settings, build a list of defaults
- defaults set
- call admin_apply_default_settings - but only if we had new defaults applied
It looks like MDL-62777 covers the case where a default settings value may depend on another setting - but not where a settings even "existing" in the settings tree depends on another setting.