Fix logging

This commit is contained in:
spikecodes 2021-02-24 11:00:04 -08:00
parent 0a69937238
commit 47d01a0dca
No known key found for this signature in database
GPG Key ID: 004CECFF9B463BCB

View File

@ -129,6 +129,8 @@ async fn main() -> tide::Result<()> {
let listener = format!("{}:{}", address, port); let listener = format!("{}:{}", address, port);
println!("Starting Libreddit...");
// Start HTTP server // Start HTTP server
let mut app = tide::new(); let mut app = tide::new();
@ -244,7 +246,9 @@ async fn main() -> tide::Result<()> {
// Default service in case no routes match // Default service in case no routes match
app.at("*").get(|req| error(req, "Nothing here".to_string())); app.at("*").get(|req| error(req, "Nothing here".to_string()));
println!("Running Libreddit v{} on {}!", env!("CARGO_PKG_VERSION"), listener);
app.listen(&listener).await?; app.listen(&listener).await?;
Ok(println!("Running Libreddit v{} on {}!", env!("CARGO_PKG_VERSION"), listener)) Ok(())
} }