Skip to content

Commit 2cfbe4b

Browse files
committed
clippy fix
1 parent 1fe7687 commit 2cfbe4b

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

src/template_helpers.rs

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -267,20 +267,12 @@ impl MarkdownConfig for AppConfig {
267267
}
268268

269269
/// Helper to render markdown with configurable options
270+
#[derive(Default)]
270271
struct MarkdownHelper {
271272
allow_dangerous_html: bool,
272273
allow_dangerous_protocol: bool,
273274
}
274275

275-
impl Default for MarkdownHelper {
276-
fn default() -> Self {
277-
Self {
278-
allow_dangerous_html: false,
279-
allow_dangerous_protocol: false,
280-
}
281-
}
282-
}
283-
284276
impl MarkdownHelper {
285277
const ALLOW_UNSAFE: &'static str = "allow_unsafe";
286278

@@ -297,7 +289,7 @@ impl MarkdownHelper {
297289
if !options.compile.allow_dangerous_html && args.len() > 1 {
298290
if let Some(arg) = args.get(1) {
299291
if arg.value().as_str() == Some(Self::ALLOW_UNSAFE) {
300-
options.compile.allow_dangerous_html = true
292+
options.compile.allow_dangerous_html = true;
301293
}
302294
}
303295
}

0 commit comments

Comments
 (0)