diff --git a/examples/linux-inotify.rs b/examples/linux-inotify.rs index 10c73e3..16cb4dd 100644 --- a/examples/linux-inotify.rs +++ b/examples/linux-inotify.rs @@ -35,7 +35,10 @@ fn main() -> std::io::Result<()> { smol::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!();