Merge branch 'MDL-43401-master' of git://github.com/FMCorz/moodle

This commit is contained in:
Eloy Lafuente (stronk7) 2014-01-21 01:46:16 +01:00
commit 2079744b84

View file

@ -885,7 +885,11 @@ function lesson_pluginfile($course, $cm, $context, $filearea, $args, $forcedownl
$fullpath = "/$context->id/mod_lesson/$filearea/$pageid/".implode('/', $args);
} else if ($filearea === 'mediafile') {
array_shift($args); // ignore itemid - caching only
if (count($args) > 1) {
// Remove the itemid when it appears to be part of the arguments. If there is only one argument
// then it is surely the file name. The itemid is sometimes used to prevent browser caching.
array_shift($args);
}
$fullpath = "/$context->id/mod_lesson/$filearea/0/".implode('/', $args);
} else {