Skip to content

Commit 9f3ad4b

Browse files
fix useless if in dataset search
1 parent 838e4d3 commit 9f3ad4b

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

dataset/src/main/kotlin/com/cosmotech/dataset/service/DatasetServiceImpl.kt

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1033,13 +1033,14 @@ class DatasetServiceImpl(
10331033
datasetRepository
10341034
.findDatasetByTags(organizationId, datasetSearch.datasetTags.toSet(), pageable)
10351035
.toList()
1036+
} else {
1037+
datasetList =
1038+
findAllPaginated(defaultPageSize) {
1039+
datasetRepository
1040+
.findDatasetByTags(organizationId, datasetSearch.datasetTags.toSet(), it)
1041+
.toList()
1042+
}
10361043
}
1037-
datasetList =
1038-
findAllPaginated(defaultPageSize) {
1039-
datasetRepository
1040-
.findDatasetByTags(organizationId, datasetSearch.datasetTags.toSet(), it)
1041-
.toList()
1042-
}
10431044
datasetList.forEach { it.security = updateSecurityVisibility(it).security }
10441045
return datasetList
10451046
}

0 commit comments

Comments
 (0)