mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-01 14:18:15 +00:00
LibWeb: Mark stream AOs as infallible as required by the spec
There were several instances where the spec marks an AO invocation as infallible, but we were propagating WebIDL::ExceptionOr. These mostly cannot throw due to knowledge about the values they are provided. By unwinding these, we can remove a decent amount of exception handling.
This commit is contained in:
committed by
Andreas Kling
parent
3aa6ef8ac0
commit
c29916775e
@@ -130,7 +130,7 @@ WebIDL::ExceptionOr<void> FileReader::read_operation(Blob& blob, Type type, Opti
|
||||
m_error = {};
|
||||
|
||||
// 5. Let stream be the result of calling get stream on blob.
|
||||
auto stream = TRY(blob.get_stream());
|
||||
auto stream = blob.get_stream();
|
||||
|
||||
// 6. Let reader be the result of getting a reader from stream.
|
||||
auto reader = TRY(acquire_readable_stream_default_reader(*stream));
|
||||
|
||||
Reference in New Issue
Block a user