File tree 1 file changed +5
-1
lines changed
src/main/kotlin/com/redhat/devtools/intellij/kubernetes/editor/describe
1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ package com.redhat.devtools.intellij.kubernetes.editor.describe
12
12
13
13
import com.intellij.openapi.application.ApplicationManager
14
14
import com.intellij.openapi.application.WriteAction
15
+ import com.intellij.openapi.application.invokeLater
15
16
import com.intellij.openapi.fileEditor.FileDocumentManager
16
17
import com.intellij.openapi.fileEditor.FileEditor
17
18
import com.intellij.openapi.fileEditor.FileEditorManager
@@ -96,7 +97,10 @@ open class DescriptionViewerFactory protected constructor() {
96
97
}
97
98
98
99
private fun openNewEditor (file : VirtualFile , project : Project ) {
99
- FileEditorManager .getInstance(project).openFile(file, true )
100
+ val fileEditorManager = FileEditorManager .getInstance(project) ? : return
101
+ invokeLater {
102
+ fileEditorManager.openFile(file, true )
103
+ }
100
104
}
101
105
102
106
private fun getOpenedEditor (resource : HasMetadata , project : Project ): FileEditor ? {
You can’t perform that action at this time.
0 commit comments