mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-09-27 22:46:22 +02:00
clener code
This commit is contained in:
@@ -41,7 +41,7 @@ class CrashReportCache(
|
|||||||
null
|
null
|
||||||
}
|
}
|
||||||
|
|
||||||
suspend fun writeReport(report: String) {
|
fun writeReport(report: String) {
|
||||||
val trace = outputStream()
|
val trace = outputStream()
|
||||||
trace.write(report.toByteArray())
|
trace.write(report.toByteArray())
|
||||||
trace.close()
|
trace.close()
|
||||||
|
@@ -62,7 +62,7 @@ abstract class OpCrypto internal constructor() : OpUnary() {
|
|||||||
val digest = MessageDigest.getInstance(this.hashLibName())
|
val digest = MessageDigest.getInstance(this.hashLibName())
|
||||||
var chunk = ctx.read(1048576)
|
var chunk = ctx.read(1048576)
|
||||||
|
|
||||||
while (chunk != null && chunk.size > 0) {
|
while (chunk.isNotEmpty()) {
|
||||||
digest.update(chunk)
|
digest.update(chunk)
|
||||||
chunk = ctx.read(1048576)
|
chunk = ctx.read(1048576)
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user