Compare commits

...

2 Commits

Author SHA1 Message Date
941a486217 bump version to 1.2.2
All checks were successful
/ publish (push) Successful in 2m32s
2025-11-10 18:08:28 +01:00
3a0a947fb0 fix padding
again
2025-11-10 18:08:21 +01:00
3 changed files with 9 additions and 9 deletions

View File

@@ -1,5 +1,5 @@
group = "com.infendro"
version = "1.2.1"
version = "1.2.2"
repositories {
mavenCentral()

View File

@@ -40,10 +40,10 @@ fun ByteArray.padStart(
padByte: Byte,
): ByteArray {
return buildList {
repeat(length - size) {
repeat(length - this@padStart.size) {
add(padByte)
}
addAll(this)
addAll(this@padStart)
}.toByteArray()
}
@@ -52,8 +52,8 @@ fun ByteArray.padEnd(
padByte: Byte,
): ByteArray {
return buildList {
addAll(this)
repeat(length - size) {
addAll(this@padEnd)
repeat(length - this@padEnd.size) {
add(padByte)
}
}.toByteArray()

View File

@@ -37,10 +37,10 @@ fun UByteArray.padStart(
padByte: UByte,
): UByteArray {
return buildList {
repeat(length - size) {
repeat(length - this@padStart.size) {
add(padByte)
}
addAll(this)
addAll(this@padStart)
}.toUByteArray()
}
@@ -49,8 +49,8 @@ fun UByteArray.padEnd(
padByte: UByte,
): UByteArray {
return buildList {
addAll(this)
repeat(length - size) {
addAll(this@padEnd)
repeat(length - this@padEnd.size) {
add(padByte)
}
}.toUByteArray()