diff --git a/java/openapi/src/com/intellij/codeInsight/completion/util/MethodParenthesesHandler.java b/java/openapi/src/com/intellij/codeInsight/completion/util/MethodParenthesesHandler.java index 3ae37c47646f..94741479362d 100644 --- a/java/openapi/src/com/intellij/codeInsight/completion/util/MethodParenthesesHandler.java +++ b/java/openapi/src/com/intellij/codeInsight/completion/util/MethodParenthesesHandler.java @@ -1,4 +1,4 @@ -// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. +// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. package com.intellij.codeInsight.completion.util; import com.intellij.codeInsight.completion.InsertionContext; @@ -14,19 +14,19 @@ public class MethodParenthesesHandler extends ParenthesesInsertHandler overloads = JBIterable.of(allItems) .map(LookupElement::getPsiElement) .filter(PsiMethod.class) @@ -35,13 +35,14 @@ public class MethodParenthesesHandler extends ParenthesesInsertHandler methods) { + public static @NotNull ThreeState hasParameters(@NotNull List methods) { boolean hasEmpty = methods.isEmpty(); boolean hasNonEmpty = false; for (PsiMethod method : methods) { if (!method.getParameterList().isEmpty()) { hasNonEmpty = true; - } else { + } + else { hasEmpty = true; } }