Adds check if directory is empty