Skip to content

Commit 76dd57c

Browse files
committed
fix isInteractiveHTML on types that cast to HTML
1 parent e78a495 commit 76dd57c

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

editor/static/js/question/edit.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2436,7 +2436,13 @@ $(document).ready(function() {
24362436
if(!val || this.error()) {
24372437
return false;
24382438
}
2439-
return Numbas.jme.isType(val,'html') && val.isInteractive();
2439+
if(!Numbas.jme.isType(val,'html')) {
2440+
return false;
2441+
}
2442+
2443+
val = Numbas.jme.castToType(val, 'html');
2444+
2445+
return val.isInteractive();
24402446
},this);
24412447

24422448
this.thisLocked = ko.observable(false);

0 commit comments

Comments
 (0)