From 6fabce62950fb24c1ea59ea141de793ba28aa44f Mon Sep 17 00:00:00 2001 From: Guillaume Gomez Date: Tue, 17 Sep 2024 17:34:21 +0200 Subject: [PATCH] Remove unneeded `unwrap` filter --- src/web/page/templates.rs | 4 ---- templates/rustdoc/head.html | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/src/web/page/templates.rs b/src/web/page/templates.rs index c1f0bd6c8..c648be86e 100644 --- a/src/web/page/templates.rs +++ b/src/web/page/templates.rs @@ -247,10 +247,6 @@ pub mod filters { } } - pub fn unwrap(value: &Option) -> rinja::Result<&T> { - Ok(value.as_ref().expect("`unwrap` filter failed")) - } - pub fn split_first<'a>(value: &'a str, pat: &str) -> rinja::Result> { Ok(value.split(pat).next()) } diff --git a/templates/rustdoc/head.html b/templates/rustdoc/head.html index 3320daa4a..a865b5bd7 100644 --- a/templates/rustdoc/head.html +++ b/templates/rustdoc/head.html @@ -1,5 +1,5 @@ {%- import "macros.html" as macros -%} - +