void (@NotNull DocumentEvent e) { Document document = e.getDocument(); final VirtualFile file = getFileDocumentManager().getFile(document); if (file != null && !(file instanceof LightVirtualFile) && !ApplicationManager.getApplication().hasWriteAction(ExternalChangeAction.class)) { ThreadingAssertions.assertEventDispatchThread(); myCurrentCommandHasChanges = true; myChangedFilesInCurrentCommand.add(file); } }