File tree Expand file tree Collapse file tree 2 files changed +5
-6
lines changed
src/commonMain/kotlin/io/github/jan/supabase/compose/auth Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -52,6 +52,7 @@ kotlin {
5252 dependencies {
5353 api(project(" :gotrue-kt" ))
5454 implementation(compose.runtime)
55+ implementation(libs.krypto)
5556 }
5657 }
5758 val noDefaultMain by creating {
Original file line number Diff line number Diff line change 11package io.github.jan.supabase.compose.auth
22
3- import io.ktor.util.Digest
43import io.ktor.utils.io.core.toByteArray
4+ import korlibs.crypto.SHA256
55
6- @OptIn(ExperimentalStdlibApi ::class )
7- internal suspend fun String.hash (): String {
8- val digest = Digest (" SHA-256" )
9- digest + = this .toByteArray()
10- return digest.build().toHexString()
6+ internal fun String.hash (): String {
7+ val hash = SHA256 .digest(this .toByteArray())
8+ return hash.hex
119}
You can’t perform that action at this time.
0 commit comments