mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-27 06:43:32 +00:00
Bug 1872296 - Use the same global for promise and chunk r=smaug a=pascalc
Differential Revision: https://phabricator.services.mozilla.com/D197938
This commit is contained in:
parent
3bb09e70b8
commit
fe1b3fa586
@ -607,7 +607,7 @@ void PipeToPump::OnReadFulfilled(JSContext* aCx, JS::Handle<JS::Value> aChunk,
|
||||
// matches other engines' behavior. See
|
||||
// https://github.com/whatwg/streams/issues/1243.
|
||||
RefPtr<Promise> promise =
|
||||
Promise::CreateInfallible(mWriter->GetParentObject());
|
||||
Promise::CreateInfallible(xpc::CurrentNativeGlobal(aCx));
|
||||
promise->MaybeResolveWithUndefined();
|
||||
auto result = promise->ThenWithCycleCollectedArgsJS(
|
||||
[](JSContext* aCx, JS::Handle<JS::Value>, ErrorResult& aRv,
|
||||
|
Loading…
Reference in New Issue
Block a user