MESSENGER-4101 matomo consent changes

This commit is contained in:
Frank Rotermund
2023-03-23 13:34:30 +01:00
parent 57de18502d
commit 41479d6629
9 changed files with 127 additions and 34 deletions

View File

@@ -48,7 +48,7 @@ struct DeveloperSettingsView: View {
Alert(title: Text(BWIL10n.bwiSettingsDeveloper), dismissButton: .default(Text("Ok")))
}
Button(action: { showAlert = resetMatomoInfoScreen() }) {
Button(action: { showAlert = resetMatomoInfoScreen(mxSession: session) }) {
Text(BWIL10n.bwiSettingsDeveloperResetMatomoInfo)
.foregroundColor(Color(ThemeService.shared().theme.tintColor))
.font(.system(size: 17))
@@ -122,8 +122,12 @@ fileprivate func createNewPersonalNotesRoom(mxSession: MXSession?) -> Bool {
return true
}
fileprivate func resetMatomoInfoScreen() -> Bool {
BWIAnalytics.sharedTracker.setPromtShown(false)
fileprivate func resetMatomoInfoScreen(mxSession: MXSession?) -> Bool {
guard let mxSession = mxSession else {
return false
}
// FRROT
BWIAnalyticsAccountDataService(mxSession: mxSession)
return true
}