diff --git a/privacy/classes/local/request/contextlist.php b/privacy/classes/local/request/contextlist.php index 7e6461cfdc3..c5b9cb1aaab 100644 --- a/privacy/classes/local/request/contextlist.php +++ b/privacy/classes/local/request/contextlist.php @@ -55,6 +55,7 @@ class contextlist extends contextlist_base { $contextids[] = $context->ctxid; \context_helper::preload_from_record($context); } + $contexts->close(); $this->set_contextids(array_merge($this->get_contextids(), $contextids));