mirror of
https://github.com/servo/servo.git
synced 2025-07-24 07:40:27 +01:00
Make use of From<String> for Atom
This commit is contained in:
parent
50af73d1a2
commit
cc030df36e
7 changed files with 14 additions and 14 deletions
|
@ -536,7 +536,7 @@ impl Document {
|
|||
// Step 3 & 4
|
||||
String::from_utf8(percent_decode(fragid.as_bytes())).ok()
|
||||
// Step 5
|
||||
.and_then(|decoded_fragid| self.get_element_by_id(&Atom::from(&*decoded_fragid)))
|
||||
.and_then(|decoded_fragid| self.get_element_by_id(&Atom::from(decoded_fragid)))
|
||||
// Step 6
|
||||
.or_else(|| self.get_anchor_by_name(fragid))
|
||||
// Step 7
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue