s4

changeset 959:193d9d2ed9c9

Avoid "not defined" exception for MathJax
author HIROSE Yuuji <yuuji@gentei.org>
date Fri, 24 Dec 2021 08:39:25 +0900
parents a0b1e62df613
children 0d9caeab3d81
files s4-main.js
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line diff
     1.1 --- a/s4-main.js	Fri Dec 24 08:28:29 2021 +0900
     1.2 +++ b/s4-main.js	Fri Dec 24 08:39:25 2021 +0900
     1.3 @@ -970,7 +970,7 @@
     1.4  	}
     1.5      }
     1.6      function initMath() {
     1.7 -	mathjax = MathJax||document.getElementById("mathjax");
     1.8 +	mathjax = window.MathJax||document.getElementById("mathjax");
     1.9  	if (!mathjax) return;
    1.10  	let ta = document.querySelector("textarea");
    1.11  	if (!ta) return;