pub fn check_auth(&self) -> bool {
        // Proxy check loop, repeat check 10 times on fail.
        for _ in 0..self.error_retry {
            info!("Checking proxy authorization status");

            match self.ensure_auth() {
                Ok(()) => return true,
                Err(err) => {
                    warn!("Failed to check proxy status: {}", err);
                    info!("Sleep for {} seconds", self.error_interval.as_secs());

                    thread::sleep(self.error_interval);
                }
            }
        }

        false
    }
/// Check authorization status and login if it's necessarily. Returns `true` on success, and `false` if login
/// failed after `error_retry` number of retries.
Check authorization status and login if it's necessarily.
Check authorization status and login if it ' s necessarily .
pub fn check_auth(&self) -> bool {
        // Proxy check loop, repeat check 10 times on fail.
        for _ in 0..self.error_retry {
            info!("Checking proxy authorization status");
            match self.ensure_auth() {
                Ok(()) => return true,
                Err(err) => {
                    warn!("Failed to check proxy status: {}", err);
                    info!("Sleep for {} seconds", self.error_interval.as_secs());
                    thread::sleep(self.error_interval);
                }
            }
        }
        false
    }
pub fn check_auth ( & self ) -> bool { // Proxy check loop, repeat check 10 times on fail. for _ in 0 .. self . error_retry { info ! ( " " ) ; match self . ensure_auth ( ) { Ok ( ( ) ) => return true , Err ( err ) => { warn ! ( " " err ) ; info ! ( " " self error_interval as_secs ( ) ) ; thread :: sleep ( self . error_interval ) ; } } } false }
Check authorization status and login if it's necessarily.
Check authorization status and login if it ' s necessarily .
&self
&self