MDL-65399 mod_quiz: Handling the edge case when section name is ''

This commit is contained in:
Shamim Rezaie
2019-05-06 18:13:42 +10:00
parent fe3d98f0a0
commit 5557ec004c
4 changed files with 5 additions and 5 deletions
@@ -519,7 +519,7 @@ Y.extend(RESOURCETOOLBOX, TOOLBOX, {
delete_multiple_action: function(ev) {
var problemsection = this.find_sections_that_would_become_empty();
if (problemsection) {
if (typeof problemsection !== 'undefined') {
var alert = new M.core.alert({
title: M.util.get_string('cannotremoveslots', 'quiz'),
message: M.util.get_string('cannotremoveallsectionslots', 'quiz', problemsection)
File diff suppressed because one or more lines are too long
@@ -519,7 +519,7 @@ Y.extend(RESOURCETOOLBOX, TOOLBOX, {
delete_multiple_action: function(ev) {
var problemsection = this.find_sections_that_would_become_empty();
if (problemsection) {
if (typeof problemsection !== 'undefined') {
var alert = new M.core.alert({
title: M.util.get_string('cannotremoveslots', 'quiz'),
message: M.util.get_string('cannotremoveallsectionslots', 'quiz', problemsection)
+1 -1
View File
@@ -285,7 +285,7 @@ Y.extend(RESOURCETOOLBOX, TOOLBOX, {
delete_multiple_action: function(ev) {
var problemsection = this.find_sections_that_would_become_empty();
if (problemsection) {
if (typeof problemsection !== 'undefined') {
var alert = new M.core.alert({
title: M.util.get_string('cannotremoveslots', 'quiz'),
message: M.util.get_string('cannotremoveallsectionslots', 'quiz', problemsection)