void (final UpdatedFiles updatedFiles) { final Collection<String> newForTree = new ArrayList<>(); final Collection<String> newForUsual = new ArrayList<>(); UpdateFilesHelper.iterateAffectedFiles(updatedFiles, pair -> { AbstractVcs vcs = myVcsManager.findVcsByName(pair.getSecond()); if (vcs == null) return; if (RemoteDifferenceStrategy.ASK_TREE_PROVIDER.equals(vcs.getRemoteDifferenceStrategy())) { newForTree.add(pair.getFirst()); } else { newForUsual.add(pair.getFirst()); } }); myRemoteRevisionsStateCache.invalidate(newForTree); myRemoteRevisionsNumbersCache.invalidate(newForUsual); }