mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 08:08:12 +00:00
LibWeb: Complete the URL in href_setter() before trying to load it
Also note that setting an invalid URL here should raise a JS exception (and not navigate away). Fixes #4301.
This commit is contained in:
parent
3565d3c60c
commit
d1a5b4d906
3 changed files with 8 additions and 3 deletions
|
@ -148,7 +148,7 @@ void Window::cancel_animation_frame(i32 id)
|
|||
GUI::DisplayLink::unregister_callback(id);
|
||||
}
|
||||
|
||||
void Window::did_set_location_href(Badge<Bindings::LocationObject>, const String& new_href)
|
||||
void Window::did_set_location_href(Badge<Bindings::LocationObject>, const URL& new_href)
|
||||
{
|
||||
auto* frame = document().frame();
|
||||
if (!frame)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue