From 6b1199957b6edb37ad7c6b8620a4d38a9b227edb Mon Sep 17 00:00:00 2001 From: kwasniew Date: Wed, 27 Nov 2024 13:25:09 +0100 Subject: [PATCH] fix: show variant diff on applied CR --- .../ChangeRequest/Changes/Change/StrategyChange.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/frontend/src/component/changeRequest/ChangeRequest/Changes/Change/StrategyChange.tsx b/frontend/src/component/changeRequest/ChangeRequest/Changes/Change/StrategyChange.tsx index fd03701a168b..491987040268 100644 --- a/frontend/src/component/changeRequest/ChangeRequest/Changes/Change/StrategyChange.tsx +++ b/frontend/src/component/changeRequest/ChangeRequest/Changes/Change/StrategyChange.tsx @@ -187,10 +187,6 @@ const UpdateStrategy: FC<{ currentStrategy: IFeatureStrategy | undefined; actions?: ReactNode; }> = ({ change, changeRequestState, currentStrategy, actions }) => { - const hasVariantDiff = hasDiff( - currentStrategy?.variants || [], - change.payload.variants || [], - ); const previousTitle = changeRequestState === 'Applied' ? change.payload.snapshot?.title @@ -199,6 +195,10 @@ const UpdateStrategy: FC<{ changeRequestState === 'Applied' ? change.payload.snapshot : currentStrategy; + const hasVariantDiff = hasDiff( + referenceStrategy?.variants || [], + change.payload.variants || [], + ); return ( <>