diff --git a/app/src/main/kotlin/com/wire/android/ui/home/HomeViewModel.kt b/app/src/main/kotlin/com/wire/android/ui/home/HomeViewModel.kt index ff043e2f3ff..c27f12a278b 100644 --- a/app/src/main/kotlin/com/wire/android/ui/home/HomeViewModel.kt +++ b/app/src/main/kotlin/com/wire/android/ui/home/HomeViewModel.kt @@ -146,10 +146,7 @@ class HomeViewModel @Inject constructor( fun sendOpenProfileEvent() { analyticsManager.sendEvent( AnalyticsEvent.UserProfileOpened( - isMigrationDotActive = homeState.shouldShowCreateTeamUnreadIndicator, - appVersion = BuildConfig.VERSION_NAME, - deviceModel = Build.MODEL, - osVersion = Build.VERSION.RELEASE + isMigrationDotActive = homeState.shouldShowCreateTeamUnreadIndicator ) ) } diff --git a/app/src/test/kotlin/com/wire/android/ui/home/HomeViewModelTest.kt b/app/src/test/kotlin/com/wire/android/ui/home/HomeViewModelTest.kt index 253726ad134..3d194ba73df 100644 --- a/app/src/test/kotlin/com/wire/android/ui/home/HomeViewModelTest.kt +++ b/app/src/test/kotlin/com/wire/android/ui/home/HomeViewModelTest.kt @@ -17,9 +17,7 @@ */ package com.wire.android.ui.home -import android.os.Build import androidx.lifecycle.SavedStateHandle -import com.wire.android.BuildConfig import com.wire.android.config.CoroutineTestExtension import com.wire.android.datastore.GlobalDataStore import com.wire.android.datastore.UserDataStore @@ -110,10 +108,7 @@ class HomeViewModelTest { verify(exactly = 1) { arrangement.analyticsManager.sendEvent( AnalyticsEvent.UserProfileOpened( - isMigrationDotActive = viewModel.homeState.shouldShowCreateTeamUnreadIndicator, - appVersion = BuildConfig.VERSION_NAME, - deviceModel = Build.MODEL, - osVersion = Build.VERSION.RELEASE + isMigrationDotActive = viewModel.homeState.shouldShowCreateTeamUnreadIndicator ) ) } diff --git a/core/analytics-disabled/src/main/kotlin/com/wire/android/feature/analytics/AnonymousAnalyticsRecorderImpl.kt b/core/analytics-disabled/src/main/kotlin/com/wire/android/feature/analytics/AnonymousAnalyticsRecorderImpl.kt index f84c579fa69..74b1cf30bd0 100644 --- a/core/analytics-disabled/src/main/kotlin/com/wire/android/feature/analytics/AnonymousAnalyticsRecorderImpl.kt +++ b/core/analytics-disabled/src/main/kotlin/com/wire/android/feature/analytics/AnonymousAnalyticsRecorderImpl.kt @@ -17,4 +17,7 @@ */ package com.wire.android.feature.analytics -class AnonymousAnalyticsRecorderImpl : AnonymousAnalyticsRecorderStub() +class AnonymousAnalyticsRecorderImpl( + private val appVersion: String, + private val appName: String +) : AnonymousAnalyticsRecorderStub() diff --git a/core/analytics/src/main/kotlin/com/wire/android/feature/analytics/model/AnalyticsEvent.kt b/core/analytics/src/main/kotlin/com/wire/android/feature/analytics/model/AnalyticsEvent.kt index 02a87d254da..f05fa6d71d9 100644 --- a/core/analytics/src/main/kotlin/com/wire/android/feature/analytics/model/AnalyticsEvent.kt +++ b/core/analytics/src/main/kotlin/com/wire/android/feature/analytics/model/AnalyticsEvent.kt @@ -17,7 +17,6 @@ */ package com.wire.android.feature.analytics.model -import com.wire.android.feature.analytics.model.AnalyticsEventConstants.APP_VERSION import com.wire.android.feature.analytics.model.AnalyticsEventConstants.CALLING_ENDED import com.wire.android.feature.analytics.model.AnalyticsEventConstants.CALLING_ENDED_AV_SWITCH_TOGGLE import com.wire.android.feature.analytics.model.AnalyticsEventConstants.CALLING_ENDED_CALL_DIRECTION @@ -44,7 +43,6 @@ import com.wire.android.feature.analytics.model.AnalyticsEventConstants.CLICKED_ import com.wire.android.feature.analytics.model.AnalyticsEventConstants.CLICKED_DISMISS_CTA import com.wire.android.feature.analytics.model.AnalyticsEventConstants.CLICKED_PERSONAL_MIGRATION_CTA_EVENT import com.wire.android.feature.analytics.model.AnalyticsEventConstants.CONTRIBUTED_LOCATION -import com.wire.android.feature.analytics.model.AnalyticsEventConstants.DEVICE_MODEL import com.wire.android.feature.analytics.model.AnalyticsEventConstants.MESSAGE_ACTION_KEY import com.wire.android.feature.analytics.model.AnalyticsEventConstants.MIGRATION_DOT_ACTIVE import com.wire.android.feature.analytics.model.AnalyticsEventConstants.MODAL_BACK_TO_WIRE_CLICKED @@ -52,7 +50,6 @@ import com.wire.android.feature.analytics.model.AnalyticsEventConstants.MODAL_CO import com.wire.android.feature.analytics.model.AnalyticsEventConstants.MODAL_LEAVE_CLICKED import com.wire.android.feature.analytics.model.AnalyticsEventConstants.MODAL_OPEN_TEAM_MANAGEMENT_CLICKED import com.wire.android.feature.analytics.model.AnalyticsEventConstants.MODAL_TEAM_NAME -import com.wire.android.feature.analytics.model.AnalyticsEventConstants.OS_VERSION import com.wire.android.feature.analytics.model.AnalyticsEventConstants.PERSONAL_TEAM_CREATION_FLOW_CANCELLED import com.wire.android.feature.analytics.model.AnalyticsEventConstants.PERSONAL_TEAM_CREATION_FLOW_COMPLETED import com.wire.android.feature.analytics.model.AnalyticsEventConstants.PERSONAL_TEAM_CREATION_FLOW_STARTED_EVENT @@ -298,19 +295,13 @@ interface AnalyticsEvent { } data class UserProfileOpened( - val isMigrationDotActive: Boolean, - val appVersion: String, - val deviceModel: String, - val osVersion: String + val isMigrationDotActive: Boolean ) : AnalyticsEvent { override val key: String = USER_PROFILE_OPENED override fun toSegmentation(): Map { return mapOf( - MIGRATION_DOT_ACTIVE to isMigrationDotActive, - APP_VERSION to appVersion, - OS_VERSION to osVersion, - DEVICE_MODEL to deviceModel + MIGRATION_DOT_ACTIVE to isMigrationDotActive ) } }