Chumper\Zipper\Zipper::extractWithBlackList PHP Method

extractWithBlackList() private method

private extractWithBlackList ( $path, $filesArray )
$path
$filesArray
    private function extractWithBlackList($path, $filesArray)
    {
        $self = $this;
        $this->repository->each(function ($fileName) use($path, $filesArray, $self) {
            $oriName = $fileName;
            $currentPath = $self->getCurrentFolderPath();
            if (!empty($currentPath) && !starts_with($fileName, $currentPath)) {
                return;
            }
            if (starts_with($fileName, $filesArray)) {
                return;
            }
            $tmpPath = str_replace($self->getInternalPath(), '', $fileName);
            // We need to create the directory first in case it doesn't exist
            $full_path = $path . '/' . $tmpPath;
            $dir = substr($full_path, 0, strrpos($full_path, '/'));
            if (!is_dir($dir)) {
                $self->getFileHandler()->makeDirectory($dir, 0777, true, true);
            }
            $self->getFileHandler()->put($path . '/' . $tmpPath, $self->getRepository()->getFileStream($oriName));
        });
    }