diff --git a/mod/scorm/lib.php b/mod/scorm/lib.php index 7b13f0b2b3c..042bde35618 100644 --- a/mod/scorm/lib.php +++ b/mod/scorm/lib.php @@ -959,7 +959,7 @@ function scorm_pluginfile($course, $cm, $context, $filearea, $args, $forcedownlo $lifetime = null; if ($filearea === 'content') { - $revision = (int)array_shift($args); // prevents caching problems - ignored here + $revision = (int)array_shift($args); // Prevents caching problems - ignored here. $relativepath = implode('/', $args); $fullpath = "/$context->id/mod_scorm/content/0/$relativepath"; // TODO: add any other access restrictions here if needed! @@ -968,6 +968,7 @@ function scorm_pluginfile($course, $cm, $context, $filearea, $args, $forcedownlo if (!has_capability('moodle/course:manageactivities', $context)) { return false; } + $revision = (int)array_shift($args); // Prevents caching problems - ignored here. $relativepath = implode('/', $args); $fullpath = "/$context->id/mod_scorm/package/0/$relativepath"; $lifetime = 0; // no caching here