mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 12:19:54 +00:00
LibWeb: Make MimeSniff::MimeType::create() infallible
This commit is contained in:
parent
073bcfd386
commit
9a8db40a23
Notes:
github-actions[bot]
2024-10-14 18:48:55 +00:00
Author: https://github.com/awesomekling
Commit: 9a8db40a23
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1796
6 changed files with 19 additions and 19 deletions
|
@ -101,7 +101,7 @@ ErrorOr<DataURL> process_data_url(URL::URL const& data_url)
|
|||
|
||||
// 14. If mimeTypeRecord is failure, then set mimeTypeRecord to text/plain;charset=US-ASCII.
|
||||
if (!mime_type_record.has_value()) {
|
||||
mime_type_record = TRY(MimeSniff::MimeType::create("text"_string, "plain"_string));
|
||||
mime_type_record = MimeSniff::MimeType::create("text"_string, "plain"_string);
|
||||
TRY(mime_type_record->set_parameter("charset"_string, "US-ASCII"_string));
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue