MDL-33186 Ensure that the comment textarea exists before toggling it

This commit is contained in:
Andrew Robert Nicols 2012-05-22 11:24:24 +01:00
parent 21878be7c8
commit 088258c160

View File

@ -385,6 +385,9 @@ bodyContent: '<div class="comment-delete-confirm"><a href="#" id="confirmdelete-
},
toggle_textarea: function(focus) {
var t = Y.one('#dlg-content-'+this.client_id);
if (!t) {
return false;
}
if (focus) {
if (t.get('value') == M.str.moodle.addcomment) {
t.set('value', '');