Skip to content

Commit 75c4a2f

Browse files
icreatedicreated
authored andcommitted
renaming to defaultPageSize
1 parent fd62363 commit 75c4a2f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/main/kotlin/com/cosmotech/api/config/CsmPlatformProperties.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -492,7 +492,7 @@ data class CsmPlatformProperties(
492492

493493
data class PageSizing(
494494
/** Max result for a single page */
495-
val maxResult: Int = 50
495+
val defaultPageSize: Int = 50
496496
)
497497
}
498498

src/main/kotlin/com/cosmotech/api/utils/RedisUtils.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ package com.cosmotech.api.utils
44

55
import org.springframework.data.domain.PageRequest
66

7-
fun constructPageRequest(page: Int?, size: Int?, maxSize: Int): PageRequest? {
7+
fun constructPageRequest(page: Int?, size: Int?, defaultPageSize: Int): PageRequest? {
88
return when {
99
page != null && size != null -> PageRequest.of(page, size)
10-
page != null && size == null -> PageRequest.of(page, maxSize)
10+
page != null && size == null -> PageRequest.of(page, defaultPageSize)
1111
page == null && size != null -> PageRequest.of(0, size)
1212
else -> null
1313
}

0 commit comments

Comments
 (0)