From 90d42dfc845f560303c4222103b9b231fc4646b1 Mon Sep 17 00:00:00 2001 From: Ilya Tregubov Date: Tue, 12 Jan 2021 11:21:30 +0200 Subject: [PATCH] MDL-70528 h5pactivity: Fix block can't be added to h5pactivity page. --- mod/h5pactivity/lib.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mod/h5pactivity/lib.php b/mod/h5pactivity/lib.php index 1b66fafb823..4d8acbf8206 100644 --- a/mod/h5pactivity/lib.php +++ b/mod/h5pactivity/lib.php @@ -314,11 +314,11 @@ function h5pactivity_reset_gradebook(int $courseid, string $type=''): void { * Return a list of page types * * @param string $pagetype current page type - * @param stdClass $parentcontext Block's parent context + * @param stdClass|null $parentcontext Block's parent context * @param stdClass $currentcontext Current context of block * @return array array of page types and it's names */ -function h5pactivity_page_type_list(string $pagetype, stdClass $parentcontext, stdClass $currentcontext): array { +function h5pactivity_page_type_list(string $pagetype, ?stdClass $parentcontext, stdClass $currentcontext): array { $modulepagetype = [ 'mod-h5pactivity-*' => get_string('page-mod-h5pactivity-x', 'h5pactivity'), ]; -- 2.11.4.GIT