def valid_directory?(entry)
      File.directory?(source.join(entry)) && !IGNORE_DIR.include?(File.basename(entry))
    end
def valid_directory?(entry)
      File.directory?(source.join(entry)) && !IGNORE_DIR.include?(File.basename(entry))
    end
Check if path is a valid directory.