Fix lifetimes.
This commit is contained in:
parent
42dbda494a
commit
3041a575f9
@ -668,17 +668,17 @@ pub enum LinkType<'s> {
|
|||||||
|
|
||||||
impl<'s> RegularLink<'s> {
|
impl<'s> RegularLink<'s> {
|
||||||
/// Orgify the raw_link if it contains line breaks.
|
/// Orgify the raw_link if it contains line breaks.
|
||||||
pub fn get_raw_link(&'s self) -> Cow<'s, str> {
|
pub fn get_raw_link<'b>(&'b self) -> Cow<'b, str> {
|
||||||
coalesce_whitespace_if_line_break(&self.raw_link)
|
coalesce_whitespace_if_line_break(&self.raw_link)
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Orgify the path if it contains line breaks.
|
/// Orgify the path if it contains line breaks.
|
||||||
pub fn get_path(&'s self) -> Cow<'s, str> {
|
pub fn get_path<'b>(&'b self) -> Cow<'b, str> {
|
||||||
coalesce_whitespace_if_line_break(&self.path)
|
coalesce_whitespace_if_line_break(&self.path)
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Orgify the search_option if it contains line breaks.
|
/// Orgify the search_option if it contains line breaks.
|
||||||
pub fn get_search_option(&'s self) -> Option<Cow<'s, str>> {
|
pub fn get_search_option<'b>(&'b self) -> Option<Cow<'b, str>> {
|
||||||
self.search_option
|
self.search_option
|
||||||
.as_ref()
|
.as_ref()
|
||||||
.map(|search_option| coalesce_whitespace_if_line_break(search_option.borrow()))
|
.map(|search_option| coalesce_whitespace_if_line_break(search_option.borrow()))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user