Commit 53c74b18 authored by Ruslan Kabalin's avatar Ruslan Kabalin
Browse files

MDL-49385 block_base: Deprecate config_save function.

block_base->config_save is not used anywhere any more. If contributed plugins
rely on it, it makes no difference since it is not being called, if they do
something like $this->config_save or parent::config_save somewhere in their
block class instance, this will still work as deprecated function will handle
it.
parent beaceef9
...@@ -343,10 +343,12 @@ class block_base { ...@@ -343,10 +343,12 @@ class block_base {
* Default behavior: save all variables as $CFG properties * Default behavior: save all variables as $CFG properties
* You don't need to override this if you 're satisfied with the above * You don't need to override this if you 're satisfied with the above
* *
* @deprecated since Moodle 2.9 MDL-49385 - Please use Admin Settings functionality to save block configuration.
* @param array $data * @param array $data
* @return boolean * @return boolean
*/ */
function config_save($data) { function config_save($data) {
debugging('config_save($data) is deprecated, use Admin Settings functionality to save block configuration.', DEBUG_DEVELOPER);
foreach ($data as $name => $value) { foreach ($data as $name => $value) {
set_config($name, $value); set_config($name, $value);
} }
......
...@@ -4,6 +4,7 @@ information provided here is intended especially for developers. ...@@ -4,6 +4,7 @@ information provided here is intended especially for developers.
=== 2.9 === === 2.9 ===
* The obsolete method preferred_width() was removed (it was not doing anything) * The obsolete method preferred_width() was removed (it was not doing anything)
* Deprecated block_base::config_save as is not called anywhere and should not be used.
=== 2.8 === === 2.8 ===
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment