void () { synchronized (LOCK) { if (myDisposed) return; if (!myProject.isInitialized()) return; Set<String> newWatchedRoots = CollectionFactory.createFilePathSet(); for (VcsDirectoryMapping mapping : myNewMappings.getDirectoryMappings()) { // <Project> mappings are ignored because they should already be watched by the Project if (mapping.isDefaultMapping()) continue; AbstractVcs vcs = ProjectLevelVcsManager.getInstance(myProject).findVcsByName(mapping.getVcs()); if (vcs != null && vcs.needsLFSWatchesForRoots()) { newWatchedRoots.add(FileUtil.toCanonicalPath(mapping.getDirectory())); } } myWatches = myLfs.replaceWatchedRoots(myWatches, newWatchedRoots, null); } }