From 1f16b4d5ef2f3c6fee4de492496f9cd06fdea4b5 Mon Sep 17 00:00:00 2001 From: TriMill Date: Sun, 3 Jul 2022 17:27:38 -0400 Subject: [PATCH] forgot to delete slashes --- src/server.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/server.rs b/src/server.rs index d5a6929..c36aa3b 100644 --- a/src/server.rs +++ b/src/server.rs @@ -34,12 +34,12 @@ pub fn start(address: &str, thread_count: usize, state: Arc>) -> Ve }; let page = url.path().split("/").last().unwrap_or(""); let res = match page { - "/rss.xml" => { + "rss.xml" => { let guard = state.lock().unwrap(); let header = tiny_http::Header::from_bytes(&b"Content-Type"[..], &b"text/xml"[..]).unwrap(); Response::from_string(&guard.rss).with_header(header) }, - "/status" => { + "status" => { let guard = state.lock().unwrap(); Response::from_string(guard.status.as_ref().unwrap_or(&"Status page disabled".into())) },