From f18e8b0cdd4c236f6992aafa1bfee853c3840a20 Mon Sep 17 00:00:00 2001 From: "Val Erastov (xibyte)" Date: Fri, 26 Jun 2020 02:25:47 -0700 Subject: [PATCH] always compact initial polynomial in case of some constants become null --- web/app/sketcher/constr/AlgNumSystem.ts | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/web/app/sketcher/constr/AlgNumSystem.ts b/web/app/sketcher/constr/AlgNumSystem.ts index 4e8478c7..39ea992a 100644 --- a/web/app/sketcher/constr/AlgNumSystem.ts +++ b/web/app/sketcher/constr/AlgNumSystem.ts @@ -179,19 +179,14 @@ export class AlgNumSubSystem { const polynomial = this.polynomials[i]; this.polyToConstr.set(polynomial, c); - let touched = false; c.objects.forEach(obj => { if (!this.owns(obj)) { obj.visitParams(p => { - if (polynomial.eliminate(p, p.get())) { - touched = true; - } + polynomial.eliminate(p, p.get()); }); } }); - if (touched) { - polynomial.compact(); - } + polynomial.compact(); } });