From a8a2705a667f76cf553fb33b0faa24c3845bf56e Mon Sep 17 00:00:00 2001 From: Nadya Zabrodina Date: Wed, 2 Nov 2016 13:38:01 +0300 Subject: [PATCH] [vcs]: change getDoc to getCachedDoc to avoid document creation --- .../openapi/vcs/changes/ChangeListCompletionContributor.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangeListCompletionContributor.java b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangeListCompletionContributor.java index 214f9e5d2cb8..8b39e8e92332 100644 --- a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangeListCompletionContributor.java +++ b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangeListCompletionContributor.java @@ -35,7 +35,7 @@ public class ChangeListCompletionContributor extends CompletionContributor imple @Override public void fillCompletionVariants(@NotNull final CompletionParameters parameters, @NotNull final CompletionResultSet result) { final PsiFile file = parameters.getOriginalFile(); - final Document document = PsiDocumentManager.getInstance(file.getProject()).getDocument(file); + final Document document = PsiDocumentManager.getInstance(file.getProject()).getCachedDocument(file); if (document == null) return; ComboBox comboBox = document.getUserData(COMBO_BOX_KEY); if (comboBox == null) return;