From 41efafc41cebdba86fca328878045543080bcf16 Mon Sep 17 00:00:00 2001 From: Mikhail Pyltsin Date: Tue, 3 Jun 2025 10:20:52 +0200 Subject: [PATCH] [command-completion] EA-1709598 read action to get editor GitOrigin-RevId: 767999a84f5ede334c235b52910f33fd9ae44213 --- .../codeInsight/completion/command/CommandCompletionService.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/platform/lang-impl/src/com/intellij/codeInsight/completion/command/CommandCompletionService.kt b/platform/lang-impl/src/com/intellij/codeInsight/completion/command/CommandCompletionService.kt index 3c40bbf41a54..4f47310777c0 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/completion/command/CommandCompletionService.kt +++ b/platform/lang-impl/src/com/intellij/codeInsight/completion/command/CommandCompletionService.kt @@ -358,7 +358,8 @@ private class CommandCompletionHighlightingListener( } override fun dispose() { - clear(lookup.editor) + val lookupEditor = runReadAction { lookup.editor } + clear(lookupEditor) } }