Browse Source

Merge pull request #6961 from FeatherAntennae/patch-3

Max Hilbrunner 2 years ago
parent
commit
ee9ece3a05
1 changed files with 7 additions and 5 deletions
  1. 7 5
      tutorials/plugins/running_code_in_the_editor.rst

+ 7 - 5
tutorials/plugins/running_code_in_the_editor.rst

@@ -268,14 +268,16 @@ By default, the warning only updates when closing and reopening the scene.
 
 
     func _get_configuration_warnings():
-        var warning = []
+        var warnings = []
+
         if title == "":
-            warning.append("Please set `title` to a non-empty value.")
+            warnings.append("Please set `title` to a non-empty value.")
+
         if description.length() >= 100:
-            warning.append("`description` should be less than 100 characters long.")
+            warnings.append("`description` should be less than 100 characters long.")
 
-        # Returning an empty string means "no warning".
-        return warning
+        # Returning an empty array means "no warning".
+        return warnings
 
 Instancing scenes
 -----------------