try use RecursiveDirectoryIterator where it possible
change filtering
small notes