Clean modulename before calling include. Thanks again Petr!

This commit is contained in:
moodler
2004-09-28 15:54:05 +00:00
parent 1129e06081
commit 357df17cb8
+2
View File
@@ -35,7 +35,9 @@
error("You can't modify this course!");
}
$mod->modulename = clean_filename($mod->modulename); // For safety
$modlib = "$CFG->dirroot/mod/$mod->modulename/lib.php";
if (file_exists($modlib)) {
include_once($modlib);
} else {