From 2b029e95570312de19b039c74f55298a439d6ad2 Mon Sep 17 00:00:00 2001 From: Carson McManus Date: Sun, 28 Jan 2024 19:51:06 -0500 Subject: add `--disable-indexing` cli flag to completely disable directory indexing --- src/renderer.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/renderer.rs') diff --git a/src/renderer.rs b/src/renderer.rs index 3b62704..b691bca 100644 --- a/src/renderer.rs +++ b/src/renderer.rs @@ -687,7 +687,7 @@ pub fn render_error( p { (error) } } // WARN don't expose random route! - @if conf.route_prefix.is_empty() { + @if conf.route_prefix.is_empty() && !conf.disable_indexing { div.error-nav { a.error-back href=(return_address) { "Go back to file listing" -- cgit v1.2.3