mirror of
https://github.com/InsanusMokrassar/MicroUtils.git
synced 2024-12-03 15:30:10 +00:00
Compare commits
3 Commits
11a36153cc
...
e5dd4363f1
Author | SHA1 | Date | |
---|---|---|---|
e5dd4363f1 | |||
a3a48bbaac | |||
5e716fb9a8 |
@ -1,5 +1,12 @@
|
||||
# Changelog
|
||||
|
||||
## 0.11.12
|
||||
|
||||
* `Repos`:
|
||||
* `Common`:
|
||||
* `JVM`:
|
||||
* Fixes in `ReadFileKeyValueRepo` methods (`values`/`keys`)
|
||||
|
||||
## 0.11.11
|
||||
|
||||
* `Crypto`:
|
||||
|
@ -14,5 +14,5 @@ crypto_js_version=4.1.1
|
||||
# Project data
|
||||
|
||||
group=dev.inmo
|
||||
version=0.11.11
|
||||
android_code_version=135
|
||||
version=0.11.12
|
||||
android_code_version=136
|
||||
|
@ -34,7 +34,7 @@ class FileReadKeyValueRepo(
|
||||
override suspend fun values(pagination: Pagination, reversed: Boolean): PaginationResult<File> {
|
||||
val count = count()
|
||||
val resultPagination = if (reversed) pagination.reverse(count) else pagination
|
||||
val filesPaths = folder.list() ?.copyOfRange(resultPagination.firstIndex, resultPagination.lastIndex) ?: return emptyPaginationResult()
|
||||
val filesPaths = folder.list() ?.copyOfRange(resultPagination.firstIndex, resultPagination.lastIndexExclusive) ?: return emptyPaginationResult()
|
||||
if (reversed) {
|
||||
filesPaths.reverse()
|
||||
}
|
||||
@ -47,7 +47,7 @@ class FileReadKeyValueRepo(
|
||||
override suspend fun keys(pagination: Pagination, reversed: Boolean): PaginationResult<String> {
|
||||
val count = count()
|
||||
val resultPagination = if (reversed) pagination.reverse(count) else pagination
|
||||
val filesPaths = folder.list() ?.copyOfRange(resultPagination.firstIndex, resultPagination.lastIndex) ?: return emptyPaginationResult()
|
||||
val filesPaths = folder.list() ?.copyOfRange(resultPagination.firstIndex, resultPagination.lastIndexExclusive) ?: return emptyPaginationResult()
|
||||
if (reversed) {
|
||||
filesPaths.reverse()
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user