mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
Remove some usage of unsafe code in Promise
This commit is contained in:
parent
555fa75b2c
commit
51e22fbc26
4 changed files with 69 additions and 73 deletions
|
@ -810,7 +810,7 @@ def getJSToNativeConversionInfo(type, descriptorProvider, failureCode=None,
|
|||
if !JS_WrapValue(*cx, valueToResolve.handle_mut()) {
|
||||
$*{exceptionCode}
|
||||
}
|
||||
match Promise::new_resolved(&promiseGlobal, *cx, valueToResolve.handle()) {
|
||||
match Promise::new_resolved(&promiseGlobal, cx, valueToResolve.handle()) {
|
||||
Ok(value) => value,
|
||||
Err(error) => {
|
||||
throw_dom_exception(*cx, &promiseGlobal, error);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue