From 7fcb1525e7ef9b4d898e42af5e18bc031b149825 Mon Sep 17 00:00:00 2001 From: Tony Giorgio Date: Tue, 14 May 2024 22:22:33 -0500 Subject: [PATCH] Rename balance update method --- src/core.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core.rs b/src/core.rs index 868ed16..79ebad0 100644 --- a/src/core.rs +++ b/src/core.rs @@ -61,8 +61,8 @@ impl HarborCore { .unwrap(); } - // TODO: probably just do this in core_loaded? - async fn set_balance(&self) { + // Sends updates to the UI to refelect the initial state + async fn init_ui_state(&self) { self.msg(CoreUIMsg::BalanceUpdated(self.balance)).await; } @@ -294,7 +294,7 @@ pub fn run_core() -> Subscription { async fn process_core(core_handle: &mut bridge::CoreHandle, core: &HarborCore) { // Initialize the ui's state - core.set_balance().await; + core.init_ui_state().await; loop { let msg = core_handle.recv().await;