Skip to content

Commit b233ef0

Browse files
committed
Make sure is defined before using it.
1 parent af0bab2 commit b233ef0

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

ts/core/MathDocument.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1065,7 +1065,7 @@ export abstract class AbstractMathDocument<N, T, D> implements MathDocument<
10651065
try {
10661066
this.compileMath(math);
10671067
} catch (err) {
1068-
if (action) {
1068+
if (action && err.retry) {
10691069
return err.retry.then(() =>
10701070
this.compileAction(action, item, recompile)
10711071
);
@@ -1104,7 +1104,7 @@ export abstract class AbstractMathDocument<N, T, D> implements MathDocument<
11041104
try {
11051105
this.compileMath(math);
11061106
} catch (err) {
1107-
if (action) {
1107+
if (action && err.retry) {
11081108
return err.retry.then(() =>
11091109
this.recompileAction(action, recompile, i)
11101110
);

0 commit comments

Comments
 (0)