1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-11-04 11:51:45 +03:00

Merge pull request #5211 from matrix-org/t3chguy/fix/15173

Hide Analytics sections if piwik config is not provided
This commit is contained in:
Michael Telatynski
2020-09-16 16:34:55 +01:00
committed by GitHub
4 changed files with 35 additions and 25 deletions

View File

@@ -1233,8 +1233,8 @@ export default class MatrixChat extends React.PureComponent<IProps, IState> {
StorageManager.tryPersistStorage();
if (SettingsStore.getValue("showCookieBar") && this.props.config.piwik && navigator.doNotTrack !== "1") {
showAnalyticsToast(this.props.config.piwik && this.props.config.piwik.policyUrl);
if (SettingsStore.getValue("showCookieBar") && Analytics.canEnable()) {
showAnalyticsToast(this.props.config.piwik?.policyUrl);
}
}