don't create editor in air if we can't find an editor for the element (EA-72968 - TDDE: TraceableDisposable.throwDisposalError)
This commit is contained in:
+1
-1
@@ -131,7 +131,7 @@ public abstract class IntentionBasedInspection<TElement : JetElement>(
|
|||||||
val editorFactory = EditorFactory.getInstance()
|
val editorFactory = EditorFactory.getInstance()
|
||||||
|
|
||||||
val editors = editorFactory.getEditors(document)
|
val editors = editorFactory.getEditors(document)
|
||||||
return if (editors.isEmpty()) editorFactory.createEditor(document) else editors[0]
|
return if (editors.isEmpty()) null else editors[0]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user