Remove event cache feature flag (#4719)
This commit is contained in:
parent
1599e038d4
commit
44d77a6048
6 changed files with 8 additions and 16 deletions
|
|
@ -193,7 +193,7 @@ private fun RoomListModalBottomSheetContent(
|
||||||
),
|
),
|
||||||
style = ListItemStyle.Destructive,
|
style = ListItemStyle.Destructive,
|
||||||
)
|
)
|
||||||
if (contextMenu.eventCacheFeatureFlagEnabled) {
|
if (contextMenu.displayClearRoomCacheAction) {
|
||||||
ListItem(
|
ListItem(
|
||||||
headlineContent = {
|
headlineContent = {
|
||||||
Text(text = "Clear cache for this room")
|
Text(text = "Clear cache for this room")
|
||||||
|
|
|
||||||
|
|
@ -264,8 +264,7 @@ class RoomListPresenter @Inject constructor(
|
||||||
isFavorite = event.roomSummary.isFavorite,
|
isFavorite = event.roomSummary.isFavorite,
|
||||||
markAsUnreadFeatureFlagEnabled = featureFlagService.isFeatureEnabled(FeatureFlags.MarkAsUnread),
|
markAsUnreadFeatureFlagEnabled = featureFlagService.isFeatureEnabled(FeatureFlags.MarkAsUnread),
|
||||||
hasNewContent = event.roomSummary.hasNewContent,
|
hasNewContent = event.roomSummary.hasNewContent,
|
||||||
eventCacheFeatureFlagEnabled = appPreferencesStore.isDeveloperModeEnabledFlow().first() &&
|
displayClearRoomCacheAction = appPreferencesStore.isDeveloperModeEnabledFlow().first(),
|
||||||
featureFlagService.isFeatureEnabled(FeatureFlags.EventCache),
|
|
||||||
)
|
)
|
||||||
contextMenuState.value = initialState
|
contextMenuState.value = initialState
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -51,8 +51,8 @@ data class RoomListState(
|
||||||
val isDm: Boolean,
|
val isDm: Boolean,
|
||||||
val isFavorite: Boolean,
|
val isFavorite: Boolean,
|
||||||
val markAsUnreadFeatureFlagEnabled: Boolean,
|
val markAsUnreadFeatureFlagEnabled: Boolean,
|
||||||
val eventCacheFeatureFlagEnabled: Boolean,
|
|
||||||
val hasNewContent: Boolean,
|
val hasNewContent: Boolean,
|
||||||
|
val displayClearRoomCacheAction: Boolean,
|
||||||
) : ContextMenu
|
) : ContextMenu
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -31,5 +31,5 @@ internal fun aContextMenuShown(
|
||||||
markAsUnreadFeatureFlagEnabled = true,
|
markAsUnreadFeatureFlagEnabled = true,
|
||||||
hasNewContent = hasNewContent,
|
hasNewContent = hasNewContent,
|
||||||
isFavorite = isFavorite,
|
isFavorite = isFavorite,
|
||||||
eventCacheFeatureFlagEnabled = false,
|
displayClearRoomCacheAction = false,
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -297,8 +297,8 @@ class RoomListPresenterTest {
|
||||||
isDm = false,
|
isDm = false,
|
||||||
isFavorite = false,
|
isFavorite = false,
|
||||||
markAsUnreadFeatureFlagEnabled = true,
|
markAsUnreadFeatureFlagEnabled = true,
|
||||||
eventCacheFeatureFlagEnabled = false,
|
|
||||||
hasNewContent = false,
|
hasNewContent = false,
|
||||||
|
displayClearRoomCacheAction = false,
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
@ -315,8 +315,8 @@ class RoomListPresenterTest {
|
||||||
isDm = false,
|
isDm = false,
|
||||||
isFavorite = true,
|
isFavorite = true,
|
||||||
markAsUnreadFeatureFlagEnabled = true,
|
markAsUnreadFeatureFlagEnabled = true,
|
||||||
eventCacheFeatureFlagEnabled = false,
|
|
||||||
hasNewContent = false,
|
hasNewContent = false,
|
||||||
|
displayClearRoomCacheAction = false,
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
@ -344,8 +344,8 @@ class RoomListPresenterTest {
|
||||||
isFavorite = false,
|
isFavorite = false,
|
||||||
markAsUnreadFeatureFlagEnabled = true,
|
markAsUnreadFeatureFlagEnabled = true,
|
||||||
// true here.
|
// true here.
|
||||||
eventCacheFeatureFlagEnabled = true,
|
|
||||||
hasNewContent = false,
|
hasNewContent = false,
|
||||||
|
displayClearRoomCacheAction = true,
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
@ -375,8 +375,8 @@ class RoomListPresenterTest {
|
||||||
isDm = false,
|
isDm = false,
|
||||||
isFavorite = false,
|
isFavorite = false,
|
||||||
markAsUnreadFeatureFlagEnabled = true,
|
markAsUnreadFeatureFlagEnabled = true,
|
||||||
eventCacheFeatureFlagEnabled = false,
|
|
||||||
hasNewContent = false,
|
hasNewContent = false,
|
||||||
|
displayClearRoomCacheAction = false,
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -147,13 +147,6 @@ enum class FeatureFlags(
|
||||||
defaultValue = { true },
|
defaultValue = { true },
|
||||||
isFinished = false,
|
isFinished = false,
|
||||||
),
|
),
|
||||||
EventCache(
|
|
||||||
key = "feature.event_cache",
|
|
||||||
title = "Use SDK Event cache",
|
|
||||||
description = "Warning: you must kill and restart the app for the change to take effect.",
|
|
||||||
defaultValue = { true },
|
|
||||||
isFinished = false,
|
|
||||||
),
|
|
||||||
PrintLogsToLogcat(
|
PrintLogsToLogcat(
|
||||||
key = "feature.print_logs_to_logcat",
|
key = "feature.print_logs_to_logcat",
|
||||||
title = "Print logs to logcat",
|
title = "Print logs to logcat",
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue