void () { if (myDeletedFiles.isEmpty()) return; Set<String> copiedAddedMoved = new HashSet<>(); for (VirtualFile file : myCopyFromMap.keySet()) { copiedAddedMoved.add(file.getPath()); } for (VirtualFile file : myAddedFiles) { copiedAddedMoved.add(file.getPath()); } for (MovedFileInfo movedFileInfo : myMovedFiles) { copiedAddedMoved.add(movedFileInfo.myNewPath); } myDeletedFiles.removeIf(path -> copiedAddedMoved.contains(path.getPath())); }