]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-17533: FIxing random input toggle issue in settings page
authorRevanshu Paliwal <revanshu.paliwal@sonarsource.com>
Thu, 27 Oct 2022 15:19:19 +0000 (17:19 +0200)
committersonartech <sonartech@sonarsource.com>
Mon, 31 Oct 2022 20:03:00 +0000 (20:03 +0000)
server/sonar-web/src/main/js/apps/settings/components/inputs/InputForSecured.tsx

index 23bdb1d0edd92e22e002d2f71a72c75a49faf67e..4233c6d7daeb5afe0f2be9953de5818e03598998 100644 (file)
@@ -50,7 +50,7 @@ export default class InputForSecured extends React.PureComponent<Props, State> {
      *  - the value changes from outside the input (i.e. store update/reset/cancel)
      */
     if (
-      (prevProps.hasValueChanged || this.props.setting !== prevProps.setting) &&
+      (prevProps.hasValueChanged || this.props.setting.value !== prevProps.setting.value) &&
       !this.props.hasValueChanged
     ) {
       this.setState({ changing: !this.props.setting.hasValue });