Use .as_str()
instead of CowStr::Borrowed
This commit is contained in:
parent
f7983cae70
commit
6f2e1c6593
@ -934,7 +934,7 @@ pub fn into_string(self) -> String {
|
||||
if let Some(link) =
|
||||
links.iter().find(|link| &*link.original_text == broken_link.reference)
|
||||
{
|
||||
Some((CowStr::Borrowed(&link.href), CowStr::Borrowed(&link.new_text)))
|
||||
Some((link.href.as_str().into(), link.new_text.as_str().into()))
|
||||
} else {
|
||||
None
|
||||
}
|
||||
@ -1014,7 +1014,7 @@ pub fn into_string(self) -> String {
|
||||
if let Some(link) =
|
||||
links.iter().find(|link| &*link.original_text == broken_link.reference)
|
||||
{
|
||||
Some((CowStr::Borrowed(&link.href), CowStr::Borrowed(&link.new_text)))
|
||||
Some((link.href.as_str().into(), link.new_text.as_str().into()))
|
||||
} else {
|
||||
None
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user