diff --git a/middleware/src/main/java/com/anytypeio/anytype/middleware/mappers/ToCoreModelMappers.kt b/middleware/src/main/java/com/anytypeio/anytype/middleware/mappers/ToCoreModelMappers.kt index 6b4f7aa13a..0a7306c26b 100644 --- a/middleware/src/main/java/com/anytypeio/anytype/middleware/mappers/ToCoreModelMappers.kt +++ b/middleware/src/main/java/com/anytypeio/anytype/middleware/mappers/ToCoreModelMappers.kt @@ -44,6 +44,7 @@ import com.anytypeio.anytype.core_models.Relation import com.anytypeio.anytype.core_models.RelationFormat import com.anytypeio.anytype.core_models.RelationLink import com.anytypeio.anytype.core_models.RelationListWithValueItem +import com.anytypeio.anytype.core_models.Relations import com.anytypeio.anytype.core_models.SpaceUsage import com.anytypeio.anytype.core_models.TimeInSeconds import com.anytypeio.anytype.core_models.chats.Chat @@ -280,13 +281,23 @@ fun List.toCoreModels(): List = mapNotNull { block -> ) } else -> { - Block( - id = block.id, - fields = block.toCoreModelsFields(), - children = block.childrenIds, - content = Block.Content.Unsupported, - backgroundColor = block.backgroundColor.ifEmpty { null } - ) + if (block.id == Relations.FEATURED_RELATIONS) { + Block( + id = block.id, + fields = block.toCoreModelsFields(), + children = block.childrenIds, + content = Block.Content.FeaturedRelations, + backgroundColor = block.backgroundColor.ifEmpty { null } + ) + } else { + Block( + id = block.id, + fields = block.toCoreModelsFields(), + children = block.childrenIds, + content = Block.Content.Unsupported, + backgroundColor = block.backgroundColor.ifEmpty { null } + ) + } } } } diff --git a/presentation/src/main/java/com/anytypeio/anytype/presentation/search/ObjectSearchConstants.kt b/presentation/src/main/java/com/anytypeio/anytype/presentation/search/ObjectSearchConstants.kt index 32bd82d4c2..ee651d2020 100644 --- a/presentation/src/main/java/com/anytypeio/anytype/presentation/search/ObjectSearchConstants.kt +++ b/presentation/src/main/java/com/anytypeio/anytype/presentation/search/ObjectSearchConstants.kt @@ -516,8 +516,8 @@ object ObjectSearchConstants { ), DVFilter( relation = Relations.LAST_OPENED_DATE, - condition = DVFilterCondition.NOT_EQUAL, - value = null + condition = DVFilterCondition.GREATER, + value = 0.0 ) )