protected function findNewFiles(string $path) : array
    {
        $arrReturn = [];
        $arrFolders = scandir($path);
        $arrSkip = [
            '.',
            '..',
        ];
        
        foreach ($arrFolders as $file) {
            //No Folder Defaults
            if (in_array($file, $arrSkip)) {
                continue;
            }
            //Process Subfolders
            if (is_dir($path.$file)) {
                $arrSubFolderFiles = $this->findNewFiles($path.$file."/");
                $arrReturn = $this->addArrayToNewFiles($arrSubFolderFiles, $arrReturn);
                continue;
            }
            $arrReturn[] = $path.$file;
        }
        
        //Remove file from list if already processed
        foreach($arrReturn as $key => $file) {
            if (in_array($file, $this->knownUpdateFiles)) {
                unset($arrReturn[$key]);
            }
        }
        return $arrReturn;
    }
protected function findNewFiles(string $path) : array
    {
        $arrReturn = [];
        $arrFolders = scandir($path);
        $arrSkip = [
            '.',
            '..',
        ];
        
        foreach ($arrFolders as $file) {
            //No Folder Defaults
            if (in_array($file, $arrSkip)) {
                continue;
            }
            //Process Subfolders
            if (is_dir($path.$file)) {
                $arrSubFolderFiles = $this->findNewFiles($path.$file."/");
                $arrReturn = $this->addArrayToNewFiles($arrSubFolderFiles, $arrReturn);
                continue;
            }
            $arrReturn[] = $path.$file;
        }
        
        //Remove file from list if already processed
        foreach($arrReturn as $key => $file) {
            if (in_array($file, $this->knownUpdateFiles)) {
                unset($arrReturn[$key]);
            }
        }
        return $arrReturn;
    }
protected function findNewFiles ( string $ path ) : array { $ arrReturn = [ ] ; $ arrFolders = scandir ( $ path ) ; $ arrSkip = [ '.' , '..' , ] ; foreach ( $ arrFolders as $ file ) { //No Folder Defaults if ( in_array ( $ file , $ arrSkip ) ) { continue ; } //Process Subfolders if ( is_dir ( $ path . $ file ) ) { $ arrSubFolderFiles = $ this -> findNewFiles ( $ path . $ file . "/" ) ; $ arrReturn = $ this -> addArrayToNewFiles ( $ arrSubFolderFiles , $ arrReturn ) ; continue ; } $ arrReturn [ ] = $ path . $ file ; } //Remove file from list if already processed foreach ( $ arrReturn as $ key => $ file ) { if ( in_array ( $ file , $ this -> knownUpdateFiles ) ) { unset ( $ arrReturn [ $ key ] ) ; } } return $ arrReturn ; }
Creates an array of Update Files that were not yet processed
@param string $path
@return array
Creates an array of Update Files that were not yet processed