mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-42777 courses: removed unneeded category check
On course view manage page, JS was not getting initalised as category-listing is not visible, initialiseCourses is doing unnessary check for category as it takes care of empty category so it should not return on empty category
This commit is contained in:
parent
d214057cad
commit
428a1bbdb1
4 changed files with 3 additions and 14 deletions
|
@ -281,10 +281,6 @@ Console.prototype = {
|
|||
if (!listing) {
|
||||
return false;
|
||||
}
|
||||
if (!category) {
|
||||
Y.log('Couldn\'t find the current category object.', 'warn', 'moodle-course-management');
|
||||
return false;
|
||||
}
|
||||
listing.all('.listitem[data-id]').each(function(node){
|
||||
this.registerCourse(new Course({
|
||||
node : node,
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -278,9 +278,6 @@ Console.prototype = {
|
|||
if (!listing) {
|
||||
return false;
|
||||
}
|
||||
if (!category) {
|
||||
return false;
|
||||
}
|
||||
listing.all('.listitem[data-id]').each(function(node){
|
||||
this.registerCourse(new Course({
|
||||
node : node,
|
||||
|
|
4
course/yui/src/management/js/console.js
vendored
4
course/yui/src/management/js/console.js
vendored
|
@ -279,10 +279,6 @@ Console.prototype = {
|
|||
if (!listing) {
|
||||
return false;
|
||||
}
|
||||
if (!category) {
|
||||
Y.log('Couldn\'t find the current category object.', 'warn', 'moodle-course-management');
|
||||
return false;
|
||||
}
|
||||
listing.all('.listitem[data-id]').each(function(node){
|
||||
this.registerCourse(new Course({
|
||||
node : node,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue