Update collections library

master
Koitharu 2 years ago
parent 57c9d26916
commit 52e4e6b802
Signed by: Koitharu
GPG Key ID: 676DEE768C17A9D7

@ -58,7 +58,7 @@ dependencies {
implementation 'com.squareup.okio:okio:3.7.0'
api 'org.jsoup:jsoup:1.17.2'
implementation 'org.json:json:20231013'
implementation 'androidx.collection:collection-ktx:1.3.0'
implementation 'androidx.collection:collection:1.4.0'
ksp project(':kotatsu-parsers-ksp')

@ -3,6 +3,7 @@
package org.koitharu.kotatsu.parsers.util
import androidx.annotation.FloatRange
import androidx.collection.MutableIntList
import androidx.collection.arraySetOf
import java.math.BigInteger
import java.net.URLDecoder
@ -84,7 +85,7 @@ fun String.ellipsize(maxLength: Int) = if (this.length > maxLength) {
} else this
fun String.splitTwoParts(delimiter: Char): Pair<String, String>? {
val indices = ArrayList<Int>(4)
val indices = MutableIntList(4)
for ((i, c) in this.withIndex()) {
if (c == delimiter) {
indices += i

Loading…
Cancel
Save