mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 08:26:37 +02:00
MDL-64719 cache: Implement purge_current_user() in \cache
\cache::make() may return a cache_disabled subclass but callers, specifically user/lib.php:user_create_user(), invoke \cache::purge_current_user() which was only implemented by the cache_session subclass. Added empty \cache::purge_current_user() which subclasses can implement, i.e. cache_session, or not, i.e. cache_disabled.
This commit is contained in:
parent
0920f35ed9
commit
36b6444420
1 changed files with 7 additions and 0 deletions
7
cache/classes/loaders.php
vendored
7
cache/classes/loaders.php
vendored
|
@ -1284,6 +1284,13 @@ class cache implements cache_loader {
|
|||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Subclasses may support purging cache of all data belonging to the
|
||||
* current user.
|
||||
*/
|
||||
public function purge_current_user() {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue