MDL-36754 core_files: Add back missing baseurl line

This commit is contained in:
Andrew Nicols 2018-08-14 15:54:12 +08:00
parent 7fa3089753
commit 2e8d476165

View File

@ -481,6 +481,7 @@ function file_rewrite_pluginfile_urls($text, $file, $contextid, $component, $fil
$finalfile = basename($file);
$tokenfile = "token{$finalfile}";
$file = substr($file, 0, strlen($file) - strlen($finalfile)) . $tokenfile;
$baseurl = "{$CFG->wwwroot}/{$file}";
if (!$CFG->slasharguments) {
$baseurl .= "?token={$token}&file=";