From 79de07693063d23434dca11f5212fb6cd7195eb6 Mon Sep 17 00:00:00 2001 From: glyph Date: Thu, 11 Aug 2022 12:40:28 +0100 Subject: [PATCH] satisfy clippy --- src/sbot.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sbot.rs b/src/sbot.rs index 639451a..97c7d9b 100644 --- a/src/sbot.rs +++ b/src/sbot.rs @@ -19,7 +19,7 @@ use crate::db::Post; async fn init_sbot() -> Result { // Define the port on which the go-sbot is running. // Defaults to 8021 if the environment variable is not set. - let go_sbot_port = env::var("GO_SBOT_PORT").unwrap_or("8021".to_string()); + let go_sbot_port = env::var("GO_SBOT_PORT").unwrap_or_else(|_| "8021".to_string()); let keystore = Keystore::GoSbot; let ip_port = Some(format!("127.0.0.1:{}", go_sbot_port));