public function cleanup()
    {
        if ($this->isEnabled() && $this->hasPattern() && realpath($this->installDir)) {
            $paths = iterator_to_array($this->finder->in($this->installDir));

            /** @var \SplFileInfo $path */
            foreach ($paths as $path) {
                $this->filesystem->remove($path);
            }
        }
    }
public function cleanup()
    {
        if ($this->isEnabled() && $this->hasPattern() && realpath($this->installDir)) {
            $paths = iterator_to_array($this->finder->in($this->installDir));

            /** @var \SplFileInfo $path */
            foreach ($paths as $path) {
                $this->filesystem->remove($path);
            }
        }
    }
public function cleanup ( ) { if ( $ this -> isEnabled ( ) && $ this -> hasPattern ( ) && realpath ( $ this -> installDir ) ) { $ paths = iterator_to_array ( $ this -> finder -> in ( $ this -> installDir ) ) ; /** @var \SplFileInfo $path */ foreach ( $ paths as $ path ) { $ this -> filesystem -> remove ( $ path ) ; } } }
Deletes all files and directories that matches patterns.
Deletes all files and directories that matches patterns .