async fn wait_for_status_change(&mut self) -> &ClientState {
        // State cant change if disconnected
        if let ClientState::Disconnected(ref _r) = self.core_status {
            return &self.core_status;
        }

        // Yield until we receive something
        let new_status = match self.core_res.recv().await {
            Some(v) => v,
            None => {
                panic!("The event loop died without sending a new status");
            }
        };

        // Save the new status
        self.set_next_status(new_status)
    }
// Waits until the event loop sends a status change event
// This will update the current core_status field
Waits until the event loop sends a status change event
This will update the current core_status field
Waits until the event loop sends a status change event This will update the current core_status field
async fn wait_for_status_change(&mut self) -> &ClientState {
        // State cant change if disconnected
        if let ClientState::Disconnected(ref _r) = self.core_status {
            return &self.core_status;
        }
        // Yield until we receive something
        let new_status = match self.core_res.recv().await {
            Some(v) => v,
            None => {
                panic!("The event loop died without sending a new status");
            }
        };
        // Save the new status
        self.set_next_status(new_status)
    }
async fn wait_for_status_change ( & mut self ) -> & ClientState { // State cant change if disconnected if let ClientState :: Disconnected ( ref _r ) = self . core_status { return & self . core_status ; } // Yield until we receive something let new_status = match self . core_res . recv ( ) . await { Some ( v ) => v , None => { panic ! ( " " ) ; } } ; // Save the new status self . set_next_status ( new_status ) }
Waits until the event loop sends a status change event
This will update the current core_status field
Waits until the event loop sends a status change event This will update the current core_status field
&mut self