mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 15:27:35 +00:00
LibGfx: Return bool not ErrorOr<bool> from ImageDecoderPlugin::sniff()
Nobody made use of the ErrorOr return value and it just added more chance of confusion, since it was not clear if failing to sniff an image should return an error or false. The answer was false, if you returned Error you'd crash the ImageDecoder.
This commit is contained in:
parent
8d9cb538d6
commit
6cf8eeb7a4
22 changed files with 40 additions and 40 deletions
|
@ -522,7 +522,7 @@ bool WebPImageDecoderPlugin::initialize()
|
|||
return !decode_webp_header(*m_context).is_error();
|
||||
}
|
||||
|
||||
ErrorOr<bool> WebPImageDecoderPlugin::sniff(ReadonlyBytes data)
|
||||
bool WebPImageDecoderPlugin::sniff(ReadonlyBytes data)
|
||||
{
|
||||
WebPLoadingContext context;
|
||||
context.data = data;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue