diff --git a/Abstracts/HotReload.php b/Abstracts/HotReload.php index be3b7b4..e36a909 100644 --- a/Abstracts/HotReload.php +++ b/Abstracts/HotReload.php @@ -137,9 +137,10 @@ class HotReload extends AbstractProcess */ protected function clear(): void { - foreach ($this->watches as $watch) { - @inotify_rm_watch($this->pipe, $watch); - } + fclose($this->pipe); + + $this->pipe = inotify_init(); + $this->watches = []; }