mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 06:17:35 +00:00
LibWeb: Implement TransformStreamDefaultController::enqueue()
This commit is contained in:
parent
e028918a64
commit
4ae82983a4
3 changed files with 11 additions and 1 deletions
|
@ -43,6 +43,15 @@ Optional<double> TransformStreamDefaultController::desired_size()
|
|||
return readable_stream_default_controller_get_desired_size(*readable_controller);
|
||||
}
|
||||
|
||||
// https://streams.spec.whatwg.org/#ts-default-controller-enqueue
|
||||
WebIDL::ExceptionOr<void> TransformStreamDefaultController::enqueue(Optional<JS::Value> chunk)
|
||||
{
|
||||
// 1. Perform ? TransformStreamDefaultControllerEnqueue(this, chunk).
|
||||
TRY(transform_stream_default_controller_enqueue(*this, chunk.has_value() ? chunk.value() : JS::js_undefined()));
|
||||
|
||||
return {};
|
||||
}
|
||||
|
||||
// https://streams.spec.whatwg.org/#ts-default-controller-error
|
||||
WebIDL::ExceptionOr<void> TransformStreamDefaultController::error(Optional<JS::Value> reason)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue