mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Ensure that a navigation to the same URL is aborted. Fixes #10952.
This commit is contained in:
parent
810735a846
commit
5cc8de8067
4 changed files with 45 additions and 2 deletions
|
@ -66,7 +66,10 @@ impl LocationMethods for Location {
|
|||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-location-hash
|
||||
fn SetHash(&self, value: USVString) {
|
||||
fn SetHash(&self, mut value: USVString) {
|
||||
if value.0.is_empty() {
|
||||
value = USVString("#".to_owned());
|
||||
}
|
||||
self.set_url_component(value, UrlHelper::SetHash);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue