summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/gdscript/gdscript_editor.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/gdscript/gdscript_editor.cpp b/modules/gdscript/gdscript_editor.cpp
index 56540b1269..64678c7240 100644
--- a/modules/gdscript/gdscript_editor.cpp
+++ b/modules/gdscript/gdscript_editor.cpp
@@ -2444,7 +2444,7 @@ Error GDScriptLanguage::complete_code(const String &p_code, const String &p_base
context.function = parser.get_completion_function();
context.line = parser.get_completion_line();
- if (!context._class) {
+ if (!context._class || context._class->owner == NULL) {
context.base = p_owner;
context.base_path = p_base_path;
}