We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bc7f724 commit b3f84f3Copy full SHA for b3f84f3
java/src/main/kotlin/cc/unitmesh/idea/context/JavaMethodContextBuilder.kt
@@ -59,9 +59,10 @@ class JavaMethodContextBuilder : MethodContextBuilder {
59
private fun getSignatureString(method: PsiMethod?): String {
60
if (method == null) return ""
61
val text = runReadAction {
62
- cleanUp(method).text
+ cleanUp(method)?.text
63
}
64
- val trimmed = text.replace('\n', ' ').trim()
65
- return trimmed
+
+ val trimmed = text?.replace('\n', ' ')?.trim()
66
+ return trimmed ?: ""
67
68
0 commit comments