From 26198ebed0407c7dd2eba6b4768e6bc1e5171f1d Mon Sep 17 00:00:00 2001 From: mudrd8mz Date: Wed, 25 Jun 2008 15:45:21 +0000 Subject: [PATCH] MDL-15387 Always add_to_log() even in case blocks are showing. Merged from MOODLE_19_STABLE --- mod/resource/type/html/resource.class.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/mod/resource/type/html/resource.class.php b/mod/resource/type/html/resource.class.php index b446c16f44..03a6bf28ae 100644 --- a/mod/resource/type/html/resource.class.php +++ b/mod/resource/type/html/resource.class.php @@ -50,6 +50,10 @@ function display() { $formatoptions = new object(); $formatoptions->noclean = true; + // fix for MDL-9021, thanks Etienne Roz + // fix for MDL-15387, thanks to John Beedell + add_to_log($course->id, "resource", "view", "view.php?id={$cm->id}", $resource->id, $cm->id); + /// Are we displaying the course blocks? if ($this->resource->options == 'showblocks') { @@ -72,9 +76,6 @@ function display() { $pagetitle = strip_tags($course->shortname.': '.format_string($resource->name)); $inpopup = optional_param('inpopup', '', PARAM_BOOL); - // fix for MDL-9021, thanks Etienne Roz - add_to_log($course->id, "resource", "view", "view.php?id={$cm->id}", $resource->id, $cm->id); - if ($resource->popup) { if ($inpopup) { /// Popup only -- 2.39.5