pub fn check_and_update_config(&self) -> bool {
        if let Ok(ev) = self.receiver.try_recv() {
            match ev {
                DebouncedEvent::Write(p)
                | DebouncedEvent::Create(p)
                | DebouncedEvent::Chmod(p) => {
                    if let Some(file_name) = p.file_name() {
                        // Make sure the file that was changed is our file, since we watch the
                        // entire directory.
                        if file_name == CONFIG_FILENAME!() && Config::try_reload(p) {
                            return true;
                        }
                    }
                }

                _ => (),
            }
        }

        false
    }
// Returns true if config was updated, false if not.
Returns true if config was updated, false if not.
Returns true if config was updated false if not .
pub fn check_and_update_config(&self) -> bool {
        if let Ok(ev) = self.receiver.try_recv() {
            match ev {
                DebouncedEvent::Write(p)
                | DebouncedEvent::Create(p)
                | DebouncedEvent::Chmod(p) => {
                    if let Some(file_name) = p.file_name() {
                        // Make sure the file that was changed is our file, since we watch the
                        // entire directory.
                        if file_name == CONFIG_FILENAME!() && Config::try_reload(p) {
                            return true;
                        }
                    }
                }
                _ => (),
            }
        }
        false
    }
pub fn check_and_update_config ( & self ) -> bool { if let Ok ( ev ) = self . receiver . try_recv ( ) { match ev { DebouncedEvent :: Write ( p ) | DebouncedEvent :: Create ( p ) | DebouncedEvent :: Chmod ( p ) => { if let Some ( file_name ) = p . file_name ( ) { // Make sure the file that was changed is our file, since we watch the // entire directory. if file_name == CONFIG_FILENAME ! ( ) && Config :: try_reload ( p ) { return true ; } } } _ => ( ) , } } false }
Returns true if config was updated, false if not.
Returns true if config was updated false if not .
&self
&self