summaryrefslogtreecommitdiff
path: root/modules/gdscript/language_server
diff options
context:
space:
mode:
authorGeequlim <geequlim@gmail.com>2020-01-10 14:23:01 +0800
committerGeequlim <geequlim@gmail.com>2020-01-10 14:23:01 +0800
commit6190d42825de1dd6ed5268b696d9ee3c770b36f6 (patch)
tree2221c2b328d1ae093bfcf6ef077c467a551f65dc /modules/gdscript/language_server
parent76678b2609921f27f52c1a2e2bd62b8d2a27bb4b (diff)
LSP: Fix bracket completion for functions with one argument
Diffstat (limited to 'modules/gdscript/language_server')
-rw-r--r--modules/gdscript/language_server/gdscript_text_document.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/gdscript/language_server/gdscript_text_document.cpp b/modules/gdscript/language_server/gdscript_text_document.cpp
index 33ca4a5d15..0572c5f746 100644
--- a/modules/gdscript/language_server/gdscript_text_document.cpp
+++ b/modules/gdscript/language_server/gdscript_text_document.cpp
@@ -269,7 +269,7 @@ Dictionary GDScriptTextDocument::resolve(const Dictionary &p_params) {
if ((item.kind == lsp::CompletionItemKind::Method || item.kind == lsp::CompletionItemKind::Function) && !item.label.ends_with("):")) {
item.insertText = item.label + "(";
- if (symbol && symbol->detail.find(",") == -1) {
+ if (symbol && symbol->children.empty()) {
item.insertText += ")";
}
} else if (item.kind == lsp::CompletionItemKind::Event) {