From fcd2cae4e1dadf8f962e9667914faebd7e7c4980 Mon Sep 17 00:00:00 2001 From: zainkabani <77307340+zainkabani@users.noreply.github.com> Date: Thu, 17 Nov 2022 09:22:12 -0800 Subject: [PATCH] Move get_config in startup to admin branch to scope down usage (#238) --- src/client.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/client.rs b/src/client.rs index 56eac27..7bdb497 100644 --- a/src/client.rs +++ b/src/client.rs @@ -367,7 +367,6 @@ where shutdown: Receiver<()>, admin_only: bool, ) -> Result, Error> { - let config = get_config(); let stats = get_reporter(); let parameters = parse_startup(bytes.clone())?; @@ -440,6 +439,7 @@ where // Authenticate admin user. let (transaction_mode, server_info) = if admin { + let config = get_config(); // Compare server and client hashes. let password_hash = md5_hash_password( &config.general.admin_username,