mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-22 09:19:03 +00:00
LibURL+LibWeb: Make URL::serialize return a String
Simplifying a bunch of uneeded error handling around the place.
This commit is contained in:
committed by
Sam Atkins
parent
d7ac0601ab
commit
0fa54c2327
@@ -628,7 +628,7 @@ public:
|
||||
// would have resulted from parsing the URL specified by candidate's src attribute's value relative to the
|
||||
// candidate's node document when the src attribute was last changed.
|
||||
auto url_record = m_candidate->document().parse_url(candiate_src);
|
||||
auto url_string = MUST(url_record.to_string());
|
||||
auto url_string = url_record.to_string();
|
||||
|
||||
// 4. ⌛ If urlString was not obtained successfully, then end the synchronous section, and jump down to the failed
|
||||
// with elements step below.
|
||||
@@ -875,7 +875,7 @@ WebIDL::ExceptionOr<void> HTMLMediaElement::select_resource()
|
||||
|
||||
// 3. ⌛ If urlString was obtained successfully, set the currentSrc attribute to urlString.
|
||||
if (url_record.is_valid())
|
||||
m_current_src = MUST(url_record.to_string());
|
||||
m_current_src = url_record.to_string();
|
||||
|
||||
// 4. End the synchronous section, continuing the remaining steps in parallel.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user