got rid of directory sort for scandir for compatibility.