mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 07:30:19 +00:00
LibWeb: Compare navigable active_url with fragments included
This was previously negated due to a misread of https://url.spec.whatwg.org/#concept-url-equals. This change fixes a bunch of WPT crashes such as "/html/browsers/history/the-history-interface/001".
This commit is contained in:
parent
3804c4dea1
commit
f1cab5de7a
Notes:
github-actions[bot]
2024-10-13 04:48:35 +00:00
Author: https://github.com/sin-ack Commit: https://github.com/LadybirdBrowser/ladybird/commit/f1cab5de7a0 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1759
1 changed files with 1 additions and 1 deletions
|
@ -1289,7 +1289,7 @@ WebIDL::ExceptionOr<void> Navigable::navigate(NavigateParams params)
|
|||
// 1. If url equals navigable's active document's URL,
|
||||
// and initiatorOriginSnapshot is same origin with targetNavigable's active document's origin,
|
||||
// then set historyHandling to "replace".
|
||||
if (url.equals(active_document.url(), URL::ExcludeFragment::Yes) && initiator_origin_snapshot.is_same_origin(active_document.origin()))
|
||||
if (url == active_document.url() && initiator_origin_snapshot.is_same_origin(active_document.origin()))
|
||||
history_handling = Bindings::NavigationHistoryBehavior::Replace;
|
||||
|
||||
// 2. Otherwise, set historyHandling to "push".
|
||||
|
|
Loading…
Reference in a new issue