Skip to content

Commit 6024a69

Browse files
committed
[Functions] Fix iOS exception message
1 parent f3ec8f6 commit 6024a69

File tree

1 file changed

+2
-2
lines changed
  • firebase-functions/src/iosMain/kotlin/dev/gitlive/firebase/functions

1 file changed

+2
-2
lines changed

firebase-functions/src/iosMain/kotlin/dev/gitlive/firebase/functions/functions.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ suspend inline fun <T> T.await(function: T.(callback: (NSError?) -> Unit) -> Uni
6363
if(error == null) {
6464
job.complete(Unit)
6565
} else {
66-
job.completeExceptionally(FirebaseFunctionsException(error.toString()))
66+
job.completeExceptionally(FirebaseFunctionsException(error.localizedDescription))
6767
}
6868
}
6969
job.await()
@@ -75,7 +75,7 @@ suspend inline fun <T, reified R> T.awaitResult(function: T.(callback: (R?, NSEr
7575
if(error == null) {
7676
job.complete(result)
7777
} else {
78-
job.completeExceptionally(FirebaseFunctionsException(error.toString()))
78+
job.completeExceptionally(FirebaseFunctionsException(error.localizedDescription))
7979
}
8080
}
8181
return job.await() as R

0 commit comments

Comments
 (0)