From 29d4cc656f6e11333422e1d1808153bbb313a404 Mon Sep 17 00:00:00 2001 From: Dan Poltawski Date: Tue, 1 Dec 2015 12:43:32 +0000 Subject: [PATCH] MDL-52370 course: purge contacts cache on role rename Previously teachers would rename roles and the change would not be reflected in course listings. --- course/lib.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/course/lib.php b/course/lib.php index ba830ca0b15..851ed52a746 100644 --- a/course/lib.php +++ b/course/lib.php @@ -2486,6 +2486,8 @@ function save_local_role_names($courseid, $data) { $rolename->name = $value; $DB->insert_record('role_names', $rolename); } + // This will ensure the course contacts cache is purged.. + coursecat::role_assignment_changed($roleid, $context); } } -- 2.43.0