catch exceptions when setting HTML
thanks to Alicia for the original solution:
dee4c98e9b
This commit is contained in:
parent
13b331fb0a
commit
db5d23d9dc
@ -9,7 +9,11 @@ function _updateQA(html, fadeTime, onupdate, onshown) {
|
||||
var qa = $("#qa");
|
||||
qa.fadeTo(fadeTime, 0, function() {
|
||||
// update text
|
||||
try {
|
||||
qa.html(html);
|
||||
} catch(err) {
|
||||
qa.text("Invalid HTML on card: "+err);
|
||||
}
|
||||
_removeStylingFromMathjaxCloze();
|
||||
onupdate(qa);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user