aboutsummaryrefslogtreecommitdiffstats
path: root/src/to_html.rs
diff options
context:
space:
mode:
authorLibravatar Hocdoc <bernhardberger@gmx.at>2022-11-10 10:06:43 +0100
committerLibravatar GitHub <noreply@github.com>2022-11-10 10:06:43 +0100
commit34ea2841df53a1aafafb01c887965469344552ba (patch)
treec21d303bd0ac12bc0b81ba41556694139c5b55a6 /src/to_html.rs
parent48823f080218d5a13dbde2ed152b8144de5afef8 (diff)
downloadmarkdown-rs-34ea2841df53a1aafafb01c887965469344552ba.tar.gz
markdown-rs-34ea2841df53a1aafafb01c887965469344552ba.tar.bz2
markdown-rs-34ea2841df53a1aafafb01c887965469344552ba.zip
Refactor code-style for Rust 1.65
Closes GH-29. Reviewed-by: Titus Wormer <tituswormer@gmail.com> Co-authored-by: Bernhard Berger <bernhardberger3456@gmail.com>
Diffstat (limited to 'src/to_html.rs')
-rw-r--r--src/to_html.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/to_html.rs b/src/to_html.rs
index 2685120..1892ba1 100644
--- a/src/to_html.rs
+++ b/src/to_html.rs
@@ -685,7 +685,7 @@ fn on_enter_paragraph(context: &mut CompileContext) {
/// Handle [`Enter`][Kind::Enter]:[`Resource`][Name::Resource].
fn on_enter_resource(context: &mut CompileContext) {
context.buffer(); // We can have line endings in the resource, ignore them.
- context.media_stack.last_mut().unwrap().destination = Some("".into());
+ context.media_stack.last_mut().unwrap().destination = Some(String::new());
}
/// Handle [`Enter`][Kind::Enter]:[`ResourceDestinationString`][Name::ResourceDestinationString].