1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 06:17:35 +00:00

LibWeb: Throw the correct object when enqueuing to a readable stream

This commit is contained in:
Matthew Olsson 2023-04-25 18:22:09 -07:00 committed by Andreas Kling
parent 4c8015c1f6
commit 22e97332fc

View file

@ -513,7 +513,8 @@ WebIDL::ExceptionOr<void> readable_stream_default_controller_enqueue(ReadableStr
readable_stream_default_controller_error(controller, throw_completion.value().value());
// 2. Return enqueueResult.
return enqueue_result;
// Note: We need to return the throw_completion object here, as enqueue needs to throw the same object that the controller is errored with
return throw_completion;
}
}