mirror of
https://github.com/moodle/moodle.git
synced 2025-08-03 08:09:47 +02:00
MDL-33624 lang - remove incosistent use of placeholder
This commit is contained in:
parent
2cbdaa77ea
commit
19a8646822
8 changed files with 8 additions and 9 deletions
|
@ -143,7 +143,7 @@ if (!empty($groupid)) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$course = $DB->get_record('course', array('id'=>$group->courseid))) {
|
if (!$course = $DB->get_record('course', array('id'=>$group->courseid))) {
|
||||||
print_error(get_string('invalidcourseid', 'blog'));
|
print_error('invalidcourseid');
|
||||||
}
|
}
|
||||||
|
|
||||||
$coursecontext = get_context_instance(CONTEXT_COURSE, $course->id);
|
$coursecontext = get_context_instance(CONTEXT_COURSE, $course->id);
|
||||||
|
|
|
@ -18,11 +18,11 @@
|
||||||
$strcategories = get_string("categories");
|
$strcategories = get_string("categories");
|
||||||
|
|
||||||
if (! $course = $DB->get_record("course", array("id"=>$id))) {
|
if (! $course = $DB->get_record("course", array("id"=>$id))) {
|
||||||
print_error("invalidcourseid", 'error', '', $id);
|
print_error("invalidcourseid");
|
||||||
}
|
}
|
||||||
if ($site->id == $course->id) {
|
if ($site->id == $course->id) {
|
||||||
// can not delete frontpage!
|
// can not delete frontpage!
|
||||||
print_error("invalidcourseid", 'error', '', $id);
|
print_error("invalidcourseid");
|
||||||
}
|
}
|
||||||
|
|
||||||
$coursecontext = get_context_instance(CONTEXT_COURSE, $course->id);
|
$coursecontext = get_context_instance(CONTEXT_COURSE, $course->id);
|
||||||
|
|
|
@ -722,7 +722,7 @@ class core_course_external extends external_api {
|
||||||
// Context validation.
|
// Context validation.
|
||||||
|
|
||||||
if (! ($course = $DB->get_record('course', array('id'=>$params['courseid'])))) {
|
if (! ($course = $DB->get_record('course', array('id'=>$params['courseid'])))) {
|
||||||
throw new moodle_exception('invalidcourseid', 'error', '', $params['courseid']);
|
throw new moodle_exception('invalidcourseid', 'error');
|
||||||
}
|
}
|
||||||
|
|
||||||
// Category where duplicated course is going to be created.
|
// Category where duplicated course is going to be created.
|
||||||
|
|
|
@ -53,7 +53,7 @@
|
||||||
|
|
||||||
/// Get course
|
/// Get course
|
||||||
if (!($course = $DB->get_record('course', array('id'=>$courseid)))) {
|
if (!($course = $DB->get_record('course', array('id'=>$courseid)))) {
|
||||||
print_error('invalidcourseid', '', '', $courseid);
|
print_error('invalidcourseid');
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Only SITE users can access to this page
|
/// Only SITE users can access to this page
|
||||||
|
|
|
@ -280,7 +280,7 @@ $string['invalidcomponent'] = 'Invalid component name';
|
||||||
$string['invalidconfirmdata'] = 'Invalid confirmation data';
|
$string['invalidconfirmdata'] = 'Invalid confirmation data';
|
||||||
$string['invalidcontext'] = 'Invalid context';
|
$string['invalidcontext'] = 'Invalid context';
|
||||||
$string['invalidcourse'] = 'Invalid course';
|
$string['invalidcourse'] = 'Invalid course';
|
||||||
$string['invalidcourseid'] = 'You are trying to use an invalid course ID: ({$a})';
|
$string['invalidcourseid'] = 'You are trying to use an invalid course ID';
|
||||||
$string['invalidcourselevel'] = 'Incorrect context level';
|
$string['invalidcourselevel'] = 'Incorrect context level';
|
||||||
$string['invalidcoursemodule'] = 'Invalid course module ID';
|
$string['invalidcoursemodule'] = 'Invalid course module ID';
|
||||||
$string['invalidcoursenameshort'] = 'Invalid short course name';
|
$string['invalidcoursenameshort'] = 'Invalid short course name';
|
||||||
|
|
|
@ -37,7 +37,6 @@ $string['deletenotes'] = 'Delete all notes';
|
||||||
$string['editnote'] = 'Edit note';
|
$string['editnote'] = 'Edit note';
|
||||||
$string['enablenotes'] = 'Enable notes';
|
$string['enablenotes'] = 'Enable notes';
|
||||||
$string['groupaddnewnote'] = 'Add a common note';
|
$string['groupaddnewnote'] = 'Add a common note';
|
||||||
$string['invalidcourseid'] = 'Invalid course id: {$a}';
|
|
||||||
$string['invalidid'] = 'Invalid note ID specified';
|
$string['invalidid'] = 'Invalid note ID specified';
|
||||||
$string['invaliduserid'] = 'Invalid user id: {$a}';
|
$string['invaliduserid'] = 'Invalid user id: {$a}';
|
||||||
$string['nocontent'] = 'Note content can not be empty';
|
$string['nocontent'] = 'Note content can not be empty';
|
||||||
|
|
|
@ -41,7 +41,7 @@ if (! $cm = get_coursemodule_from_instance('data', $data->id, $data->course)) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if(! $course = $DB->get_record('course', array('id'=>$cm->course))) {
|
if(! $course = $DB->get_record('course', array('id'=>$cm->course))) {
|
||||||
print_error('invalidcourseid', '', '', $cm->course);
|
print_error('invalidcourseid');
|
||||||
}
|
}
|
||||||
|
|
||||||
// fill in missing properties needed for updating of instance
|
// fill in missing properties needed for updating of instance
|
||||||
|
|
|
@ -110,7 +110,7 @@ class core_notes_external extends external_api {
|
||||||
//check the course exists
|
//check the course exists
|
||||||
if (empty($courses[$note['courseid']])) {
|
if (empty($courses[$note['courseid']])) {
|
||||||
$success = false;
|
$success = false;
|
||||||
$errormessage = get_string('invalidcourseid', 'notes', $note['courseid']);
|
$errormessage = get_string('invalidcourseid', 'error');
|
||||||
} else {
|
} else {
|
||||||
// Ensure the current user is allowed to run this function
|
// Ensure the current user is allowed to run this function
|
||||||
$context = get_context_instance(CONTEXT_COURSE, $note['courseid']);
|
$context = get_context_instance(CONTEXT_COURSE, $note['courseid']);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue