Skip to content
Snippets Groups Projects
Commit 4f4a06d9 authored by Chris Sangwin's avatar Chris Sangwin
Browse files

Code tidy.

parent 444b9f51
No related branches found
No related tags found
No related merge requests found
......@@ -23,7 +23,10 @@
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
// The docs should be public and not require a login, so we ignore the fact we load config here without a login check.
// @codingStandardsIgnoreStart
require_once(__DIR__ . '/../../../../config.php');
// @codingStandardsIgnoreEnd
require_once(__DIR__ . '/docslib.php');
/*
......
......@@ -24,6 +24,8 @@
require_once(__DIR__ . '/../../../config.php');
require_once($CFG->libdir . '/filelib.php');
require_login();
$filename = clean_filename(get_file_argument());
$filenamesplit = explode('.', $filename);
$filetype = end($filenamesplit);
......
......@@ -29,9 +29,7 @@ $qaid = required_param('qaid', PARAM_INT);
$inputname = required_param('name', PARAM_ALPHANUMEXT);
$inputvalue = required_param('input', PARAM_RAW);
if (!isloggedin()) {
die;
}
require_login();
// This should not be necessary, but the TeX filter requires it, because it uses $OUTPUT.
$PAGE->set_context(context_system::instance());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment