MDL-14129, fix misuse string
This commit is contained in:
+3
-3
@@ -18,18 +18,18 @@
|
||||
if (!empty($id)) {
|
||||
require_login($id);
|
||||
if (!has_capability('moodle/site:backup', get_context_instance(CONTEXT_COURSE, $id))) {
|
||||
print_error('cannotusepage', 'error', "$CFG->wwwroot/login/index.php");
|
||||
print_error('cannotuseadminadminorteacher', 'error', "$CFG->wwwroot/login/index.php");
|
||||
}
|
||||
} else {
|
||||
require_login();
|
||||
if (!has_capability('moodle/site:backup', get_context_instance(CONTEXT_SYSTEM))) {
|
||||
print_error('cannotusepage', 'error', "$CFG->wwwroot/login/index.php");
|
||||
print_error('cannotuseadmin', 'error', "$CFG->wwwroot/login/index.php");
|
||||
}
|
||||
}
|
||||
|
||||
if (!empty($to)) {
|
||||
if (!has_capability('moodle/site:backup', get_context_instance(CONTEXT_COURSE, $to))) {
|
||||
print_error('cannotusepage', 'error', "$CFG->wwwroot/login/index.php");
|
||||
print_error('cannotuseadminadminorteacher', 'error', "$CFG->wwwroot/login/index.php");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -39,6 +39,8 @@ $string['cannotsetupcategory'] = 'Serious Error! Could not set up a default cour
|
||||
$string['cannotsetupsite'] = 'Serious Error! Could not set up the site!';
|
||||
$string['cannotunzipfile'] = 'Cannot unzip file.';
|
||||
$string['cannotupdaterole'] = 'Cannot update role!';
|
||||
$string['cannotuseadmin'] = 'You need to be an admin user to use this page.';
|
||||
$string['cannotuseadminadminorteacher'] = 'You need to be a teacher or admin user to use this page.';
|
||||
$string['cannotusepage'] = 'Only teacher and administrator can use this page.';
|
||||
$string['cannotviewprofile'] = 'You can not view the profile of this user.';
|
||||
$string['cantunenrollfrommetacourse'] = 'You can not unenrol from this meta course.';
|
||||
|
||||
Reference in New Issue
Block a user