From d1257efcd2f7e75aa24f84213d768a09ce244a92 Mon Sep 17 00:00:00 2001 From: hamed musallam Date: Thu, 28 Aug 2025 16:27:25 +0200 Subject: [PATCH] fix: prevent domain refresh when selecting Ft spectra --- src/component/reducer/actions/SpectraActions.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/component/reducer/actions/SpectraActions.ts b/src/component/reducer/actions/SpectraActions.ts index c6f2c024d7..6a646f5751 100644 --- a/src/component/reducer/actions/SpectraActions.ts +++ b/src/component/reducer/actions/SpectraActions.ts @@ -399,11 +399,11 @@ function handleChangeActiveSpectrum( * not refresh the y domain if the next and previous selected spectra have Ft or we do not have previous or next active spectra */ const refreshDomain = - previousActiveSpectraHasFT === undefined || - (previousActiveSpectraHasFT !== newActiveSpectraHasFT && - spectra && - spectra?.length > 0 && - spectraIds?.length > 0); + (previousActiveSpectraHasFT === undefined || + previousActiveSpectraHasFT !== newActiveSpectraHasFT) && + spectra && + spectra?.length > 0 && + spectraIds?.length > 0; /** * if the active spectrum not is FID then do not refresh the domain and the mode when the first time you activate spectrum