diff --git a/Abstracts/HotReload.php b/Abstracts/HotReload.php index cc29102..a3294c4 100644 --- a/Abstracts/HotReload.php +++ b/Abstracts/HotReload.php @@ -75,12 +75,15 @@ class HotReload extends AbstractProcess } while (!$this->isStop()) { $read = inotify_read($this->pipe); + var_dump($read); - foreach ($read as $item) { - $this->reWatch($this->watches[$item['wd']]); + if (count($read) > 0) { + $this->reload(); + + foreach (config('reload.listen') as $value) { + $this->reWatch($value); + } } - - $this->reload(); } }