diff --git a/examples/linux-inotify.rs b/examples/linux-inotify.rs index c168f63..8be2f40 100644 --- a/examples/linux-inotify.rs +++ b/examples/linux-inotify.rs @@ -37,7 +37,7 @@ fn main() -> std::io::Result<()> { future::block_on(async { // Watch events in the current directory. let mut inotify = Async::new(Inotify::init()?)?; - inotify.get_mut().add_watch(".", WatchMask::ALL_EVENTS)?; + inotify.get_mut().watches().add(".", WatchMask::ALL_EVENTS)?; println!("Watching for filesystem events in the current directory..."); println!("Try opening a file to trigger some events."); println!();