MDL-19313 Use an existing exception code

This commit is contained in:
Martin Dougiamas 2010-05-12 07:56:48 +00:00
parent 229a70996a
commit 15ac57cbc0
3 changed files with 6 additions and 6 deletions

View File

@ -45,7 +45,7 @@ $huburl = optional_param('huburl', '', PARAM_URL);
$password = optional_param('password', '', PARAM_TEXT);
$hubname = optional_param('hubname', '', PARAM_TEXT);
if (empty($huburl) or !confirm_sesskey()) {
throw new moodle_exception('cannotaccessthispage');
throw new moodle_exception('missingparameter');
}
/* TO DO

View File

@ -50,7 +50,7 @@ if (has_capability('moodle/course:publish', get_context_instance(CONTEXT_COURSE,
$huburl = optional_param('huburl', '', PARAM_URL);
$hubname = optional_param('hubname', '', PARAM_TEXT);
if (empty($huburl) or !confirm_sesskey()) {
throw new moodle_exception('cannotaccessthispage');
throw new moodle_exception('missingparameter');
}
//set the publication form

View File

@ -54,7 +54,7 @@ if (has_capability('moodle/course:publish', get_context_instance(CONTEXT_COURSE,
$huburl = optional_param('huburl', '', PARAM_URL);
$hubname = optional_param('hubname', '', PARAM_TEXT);
if (empty($huburl) or !confirm_sesskey()) {
throw new moodle_exception('cannotaccessthispage');
throw new moodle_exception('missingparameter');
}
$advertise = optional_param('advertise', false, PARAM_BOOL);