diff options
Diffstat (limited to 'cli/file_watcher.rs')
-rw-r--r-- | cli/file_watcher.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cli/file_watcher.rs b/cli/file_watcher.rs index 0f9f7d1ff..c5a92e5bf 100644 --- a/cli/file_watcher.rs +++ b/cli/file_watcher.rs @@ -261,7 +261,7 @@ pub async fn watch_func2<T: Clone, O, F>( print_config: PrintConfig, ) -> Result<(), AnyError> where - O: FnMut(T) -> F, + O: FnMut(T) -> Result<F, AnyError>, F: Future<Output = Result<(), AnyError>>, { let (watcher_sender, mut watcher_receiver) = @@ -306,7 +306,7 @@ where add_paths_to_watcher(&mut watcher, &maybe_paths.unwrap()); } }; - let operation_future = error_handler(operation(operation_args.clone())); + let operation_future = error_handler(operation(operation_args.clone())?); select! { _ = receiver_future => {}, |