Make sure svg is defined before using its width

This commit is contained in:
Davide P. Cervone 2014-05-06 07:00:29 -04:00
parent 3ebb153763
commit 214a230504

View File

@ -336,7 +336,7 @@ MathJax.Hub.Register.StartupHook("SVG Jax Ready",function () {
if (state.last && svg.X) {svg.X = 0}
line.Add(svg,line.w,0,true);
}
if (state.first && svg.w === 0) {state.nextIsFirst = true}
if (state.first && svg && svg.w === 0) {state.nextIsFirst = true}
else {delete state.nextIsFirst}
}
});