diff --git a/kiri-engine/FileListen/Scaner.php b/kiri-engine/FileListen/Scaner.php index 4cb48c5a..524c6b55 100644 --- a/kiri-engine/FileListen/Scaner.php +++ b/kiri-engine/FileListen/Scaner.php @@ -117,12 +117,20 @@ class Scaner } + private bool $isStop = false; + + public function clear() + { + $this->isStop = true; + } + + /** * @throws Exception */ public function tick() { - if ($this->process->isReloading) { + if ($this->process->isReloading || $this->isStop) { return; }