From 47d01a0dca2088b1ff7102da230e41f8cd4086d6 Mon Sep 17 00:00:00 2001 From: spikecodes <19519553+spikecodes@users.noreply.github.com> Date: Wed, 24 Feb 2021 11:00:04 -0800 Subject: [PATCH] Fix logging --- src/main.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index c692da5..baadb94 100644 --- a/src/main.rs +++ b/src/main.rs @@ -129,6 +129,8 @@ async fn main() -> tide::Result<()> { let listener = format!("{}:{}", address, port); + println!("Starting Libreddit..."); + // Start HTTP server let mut app = tide::new(); @@ -244,7 +246,9 @@ async fn main() -> tide::Result<()> { // Default service in case no routes match app.at("*").get(|req| error(req, "Nothing here".to_string())); + println!("Running Libreddit v{} on {}!", env!("CARGO_PKG_VERSION"), listener); + app.listen(&listener).await?; - Ok(println!("Running Libreddit v{} on {}!", env!("CARGO_PKG_VERSION"), listener)) + Ok(()) }