calling a javascript function and waiting for the promise with `rusty_v8`
let result = function.call(scope, recv, &[]).expect("couldnt run");/*i got this result which is a promise. now how do i get the value of the promiselet value = ??*/
let result = function.call(scope, recv, &[]).expect("couldnt run");/*i got this result which is a promise. now how do i get the value of the promiselet value = ??*/
result.is_promise
result.is_promise
is
true
true
promise state is
Pending
Pending
scope.has_pending_background_tasks()
scope.has_pending_background_tasks()
is
false
false
which confuses me. Isnt this supposed to be true if there are unresolved promises?