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

LibWeb: Implement releaseLock interface for ReadableStreamBYOBReader

This commit is contained in:
Shannon Booth 2023-08-27 13:29:32 +12:00 committed by Andrew Kaster
parent b06d80e6fd
commit 6e9aeccf90
3 changed files with 14 additions and 1 deletions

View file

@ -30,6 +30,17 @@ WebIDL::ExceptionOr<JS::NonnullGCPtr<ReadableStreamBYOBReader>> ReadableStreamBY
return reader;
}
// https://streams.spec.whatwg.org/#byob-reader-release-lock
void ReadableStreamBYOBReader::release_lock()
{
// 1. If this.[[stream]] is undefined, return.
if (!m_stream)
return;
// 2. Perform ! ReadableStreamBYOBReaderRelease(this).
readable_stream_byob_reader_release(*this);
}
void ReadableStreamBYOBReader::visit_edges(Cell::Visitor& visitor)
{
Base::visit_edges(visitor);