Skip to content

Commit

Permalink
Fix identity server settings visibility
Browse files Browse the repository at this point in the history
The IS settings got confused with the posthog settings and were only
shown if analytics were enabled.
  • Loading branch information
dbkr committed Jan 23, 2025
1 parent a0044d6 commit 5935615
Showing 1 changed file with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -319,17 +319,16 @@ export default class SecurityUserSettingsTab extends React.Component<IProps, ISt
);
}

let privacySection;
let posthogSection;
if (PosthogAnalytics.instance.isEnabled()) {
const onClickAnalyticsLearnMore = (): void => {
showAnalyticsLearnMoreDialog({
primaryButton: _t("action|ok"),
hasCancel: false,
});
};
privacySection = (
<SettingsSection heading={_t("common|privacy")}>
<DiscoverySettings />
posthogSection = (
<>
<SettingsSubsection
heading={_t("common|analytics")}
description={_t("settings|security|analytics_description")}
Expand All @@ -344,7 +343,7 @@ export default class SecurityUserSettingsTab extends React.Component<IProps, ISt
<SettingsSubsection heading={_t("settings|sessions|title")}>
<SettingsFlag name="deviceClientInformationOptIn" level={SettingLevel.ACCOUNT} />
</SettingsSubsection>
</SettingsSection>
</>
);
}

Expand Down Expand Up @@ -373,7 +372,10 @@ export default class SecurityUserSettingsTab extends React.Component<IProps, ISt
{crossSigning}
<CryptographyPanel />
</SettingsSection>
{privacySection}
<SettingsSection heading={_t("common|privacy")}>
<DiscoverySettings />
{posthogSection}
</SettingsSection>
{advancedSection}
</SettingsTab>
);
Expand Down

0 comments on commit 5935615

Please sign in to comment.