From 8785d192d671015d6128f861f6112f163179ab9e Mon Sep 17 00:00:00 2001 From: Jeremy Davis Date: Fri, 27 Oct 2023 11:00:14 +0200 Subject: [PATCH] SONAR-20382 Fix flaky portfolio test - round 4 --- .../src/main/js/app/components/extensions/Extension.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server/sonar-web/src/main/js/app/components/extensions/Extension.tsx b/server/sonar-web/src/main/js/app/components/extensions/Extension.tsx index e19e4f2aaea..b248789a7aa 100644 --- a/server/sonar-web/src/main/js/app/components/extensions/Extension.tsx +++ b/server/sonar-web/src/main/js/app/components/extensions/Extension.tsx @@ -20,6 +20,7 @@ import { withTheme } from '@emotion/react'; import { QueryClient } from '@tanstack/react-query'; import { Theme } from 'design-system'; +import { isEqual } from 'lodash'; import * as React from 'react'; import { Helmet } from 'react-helmet-async'; import { injectIntl, WrappedComponentProps } from 'react-intl'; @@ -67,7 +68,7 @@ class Extension extends React.PureComponent { if (prevProps.extension.key !== this.props.extension.key) { this.stopExtension(); this.startExtension(); - } else if (prevProps.location !== this.props.location) { + } else if (!isEqual(prevProps.location, this.props.location)) { this.startExtension(); } } -- 2.39.5