Skip to content

Commit d5e07a7

Browse files
author
Brad Horrocks
committed
toggleClass expects a boolean, not a truthy value for 2nd param
Previously we were passing in undefined, which was fine until you toggled true, then wanted to go back. see: http://api.jquery.com/toggleclass/#toggleClass-className-switch fixes CNVS-5365 test plan: - have a user with a submitted assignment that hasnt been graded - in GradeBook, open the message students who... - select "scored less than" - select "Haven't submitted yet" - select "Haven't been graded yet" - without fix, null will be displayed by the user - with the fix, everything will look normal Change-Id: Ic05b8c2eec513ef26f8f3cdf26d8b328c7a850e1 Reviewed-on: https://gerrit.instructure.com/37206 Reviewed-by: Cameron Matheson <cameron@instructure.com> Tested-by: Jenkins <jenkins@instructure.com> QA-Review: Amber Taniuchi <amber@instructure.com> Product-Review: Simon Williams <simon@instructure.com>
1 parent 9f492ad commit d5e07a7

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

public/javascripts/message_students.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,8 @@ define([
131131
$message_students_dialog.find("[name=subject]").val(currentSettings.subjectCallback(option.text, cutoff));
132132
}
133133
$message_students_dialog.find(".cutoff_holder").showIf(option.cutoff);
134-
$message_students_dialog.find(".student_list").toggleClass('show_score', option.cutoff || option.score);
134+
135+
$message_students_dialog.find(".student_list").toggleClass('show_score', !!(option.cutoff || option.score));
135136
$message_students_dialog.find("button").attr('disabled', student_ids.length == 0);
136137

137138
var student_ids_hash = {};

0 commit comments

Comments
 (0)