From 51c0f2e0585ea818053b9271e41a11ec0fe76746 Mon Sep 17 00:00:00 2001 From: Kumi Date: Mon, 8 Jul 2024 12:52:42 +0200 Subject: [PATCH] fix: remove redundant require_login call in view_content.php Removed an unnecessary require_login call from the view_content.php file. The user is already authenticated earlier in the workflow, ensuring there is no duplicate authentication process. This change streamlines the code and improves efficiency by avoiding redundant checks. --- view_content.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/view_content.php b/view_content.php index c34fde0..21b44c7 100644 --- a/view_content.php +++ b/view_content.php @@ -9,8 +9,6 @@ $cm = get_coursemodule_from_id('exp360', $id, 0, false, MUST_EXIST); $course = $DB->get_record('course', array('id' => $cm->course), '*', MUST_EXIST); $exp360 = $DB->get_record('exp360', array('id' => $cm->instance), '*', MUST_EXIST); -require_login($course, true, $cm); - $content_id = $exp360->content_id; ?>