LibWeb: Remove unused underlying_buffer_source function

This function is not used anywhere and will most likely end up causing
problems so just remove it.
This commit is contained in:
devgianlu 2025-03-01 19:23:39 +01:00 committed by Jelle Raaijmakers
parent 033ba43faf
commit cfeb916e61
Notes: github-actions[bot] 2025-03-19 12:47:50 +00:00

View file

@ -33,18 +33,6 @@ bool is_buffer_source_type(JS::Value value)
return is<JS::TypedArrayBase>(object) || is<JS::DataView>(object) || is<JS::ArrayBuffer>(object);
}
GC::Ptr<JS::ArrayBuffer> underlying_buffer_source(JS::Object& buffer_source)
{
if (is<JS::TypedArrayBase>(buffer_source))
return static_cast<JS::TypedArrayBase&>(buffer_source).viewed_array_buffer();
if (is<JS::DataView>(buffer_source))
return static_cast<JS::DataView&>(buffer_source).viewed_array_buffer();
if (is<JS::ArrayBuffer>(buffer_source))
return static_cast<JS::ArrayBuffer&>(buffer_source);
VERIFY_NOT_REACHED();
}
// https://webidl.spec.whatwg.org/#dfn-get-buffer-source-copy
ErrorOr<ByteBuffer> get_buffer_source_copy(JS::Object const& buffer_source)
{