I noticed that if I use `GlobalScope.promise` and ...
# javascript
g
I noticed that if I use
GlobalScope.promise
and in the my Promise I reject with nothing
reject()
this is not considered as an error. I can
reject(42)
or with an explicit error, but when there is nothing, it looks similar to
resolve()
with no params (
getCompletionExceptionOrNull
returns null,
isCompleted
returns true). Is there a way to differentiate both cases? And why not considering
reject()
as failed with an unknown exception from the Kotlin side?
1
t
Is it valid call in JS?
I mean reject without parameter
g
As far as I know yes, at least it works in the JS console
I use this, remove the Error line 9, and I can see that the rejected method is called
t
Looks like issue required :)
g